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
Describe the bug Arg.Any<Arg.AnyType>() does not match arguments passed by reference
To Reproduce
IMyServiceservice= Substitute.For<IMyService>();MyArgumentarg=new();
service.MyMethod(ref arg);// The following line throws.
service.Received().MyMethod(ref Arg.Any<Arg.AnyType>());publicinterfaceIMyService{voidMyMethod<T>(refTargument);}privateclassMyArgument{}
Expected behaviour Arg.Any<Arg.AnyType>() should match arguments passed by reference
Environment:
NSubstitute version: 5.1.0
NSubstitute.Analyzers version: 1.0.17
Platform: net8.0 on Windows
The text was updated successfully, but these errors were encountered:
Describe the bug
Arg.Any<Arg.AnyType>()
does not match arguments passed by referenceTo Reproduce
Expected behaviour
Arg.Any<Arg.AnyType>()
should match arguments passed by referenceEnvironment:
The text was updated successfully, but these errors were encountered: