we have significantly improved this reporting in case of verify errors. Would you want this to also be available when the verifications actually succeed too?azdlowry commented
I finally managed to take a look at version 4, and the reporting on verifications is awesome, great work.
However this is not the case I am suggesting here. What I'm suggesting is another method which has nothing to do with Verifications which just dumps out all the invocations on the mock, so we can see what actually happened.
This is useful when Mock is used at a higher level than simple unit tests such as integration tests, and dumping out all the interactions would be easier than attaching a debugger. I tried adding this feature myself and managed to get something to work but there was a few things I didn't understand about the internal workings of Moq which suggested my code wouldn't work in all cases. Even with this I was able to use it to track down a bug i wouldn't have easily found without it.
what should be the batching behavior? Argument type obviously, but what about ordering? What if the method has 2 string parameters mixed with other types?azdlowry commented
I think as a first step, just matching the parameters by position would be enough, anything more complicated may be confusing.