Isolate.WhenCalled(() => ....).CallOriginal()
would call the original method, regardless of the args
Isolate.WhenCalled(() => ....).WithArguments("X", "Y").CallOriginal()
would only call the original method when these specific values args are passed;
Keeping in mind my other post:
Isolate.WhenCalled(() => ...).WithArguments(Arg.Any, "Y").CallOriginal()
would only call the original method when the second argument is the specific value, and because of overloads that might give a signagure of (string, string) but also (int?, string), when you need to be specific about types:
Isolate.WhenCalled(() => ...).WithArguments(Arg.AnyTypeOf<string>(), "Y").CallOriginal
And then similiar for privates:
Isolate.NonPublic.WhenCalled(fake, "MethodName").WithArguments(Arg.InstanceOf<Customer>(), "Y").CallOriginal();
That's not much right? Version 5.2.2 next week? :lol:
Thanks...looking forward to whatever we get next...