Hi
There is bug regarding ref / out parameters in AAA.
The bug is that it that the value of ref parameters is not set when the default behavior is Members.ReturnRecursiveFakes.
This is the default behavior when using AAA syntax.
The workaround is to use different default behavior like Members.ReturnNulls:
// Arrange
StatusStructure fakeStatus = new StatusStructure { StatusValue = 1 };
Isolate.Fake.StaticMethods(typeof(StaticClass), Members.ReturnNulls);
Isolate.WhenCalled(() => StaticClass.GetStatus(ref fakeStatus)).WillReturn(true);
// Act
StatusStructure status = new StatusStructure();
bool result = StaticClass.GetStatus(ref status);
// Assert
Assert.AreEqual(1, status.StatusValue);
Assert.AreEqual(true, result);
This should make the test work.
I hope we'll fix this problem soon :oops: