You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Improved performance for Mock.Of<T> and mock.SetupAllProperties() as the latter now performs property setups just-in-time, instead of as an ahead-of-time batch operation. (@vanashimko, #826)
Setups with no .Returns(…) nor .CallBase() no longer return default(T) for loose mocks, but a value that is consistent with the mock's CallBase and DefaultValue[Provider] settings. (@stakx, #849)
Added
New method overload sequenceSetup.ReturnsAsync(Func<T>) (@stakx, #841)
LINQ to Mocks support for strict mocks, i.e. new method overloads for Mock.Of, Mocks.Of, mockRepository.Of, and mockRepository.OneOf that accept a MockBehavior parameter. (@stakx, #842)
mock.SetupAllProperties() now setups write-only properties for strict mocks, so that accessing such properties will not throw anymore. (@vanashimko, #836)
Regression: mock.SetupAllProperties() and Mock.Of<T> fail due to inaccessible property accessors (@Mexe13, #845)
Regression: VerifyNoOtherCalls causes stack overflow when mock setup returns the mocked object (@bash, #846)
Capture.In() no longer captures arguments when other setup arguments do not match (@ocoanet, #844).
CaptureMatch no longer invokes the capture callback when other setup arguments do not match (@ocoanet, #844).