NSubstitute icon indicating copy to clipboard operation
NSubstitute copied to clipboard

A friendly substitute for .NET mocking libraries.

Results 178 NSubstitute issues
Sort by recently updated
recently updated
newest added

Hey :) So lets say I have a factory that creates objects and I'm mocking that to make sure that it returns a mocked object with specific properties. In my...

bug
help wanted

I've just started using NSubstitute and quickly ran into a problem when my method expected a collection argument, as described here: http://stackoverflow.com/questions/12699066/nsubstitute-checking-received-methods-with-array-arguments The answer in that question works, but it...

feature-request

For example: sub.Received().MyMethod(1, "first") Should list: MyMethod(1) MyMethod(2, "first") Possibly other generic instances of method too: MyMethod("first", "second")

feature-request

It would be nice if `Call.ToString()` could print out as the call would look like. i.e. something like: ``` foreach (var call in groupReps.ReceivedCalls()) { Console.WriteLine(); } ``` Would print...

feature-request

Based on [google groups post.](https://groups.google.com/d/topic/nsubstitute/cS3J0Mila30) First of all, Do() should correspond with Returns. Secondly, it could be useful :smile:

feature-request

Right now, only CallRouter instance is added as a mixin to the substitute: ``` private ProxyGenerationOptions GetOptionsToMixinCallRouter(ICallRouter callRouter) { var options = new ProxyGenerationOptions(_allMethodsExceptCallRouterCallsHook); options.AddMixinInstance(callRouter); return options; } ``` It...

feature-request

It would be nice to have auto values disabled. I ran into a scenario for casting that was failing with the auto value, it took a bit for us to...

feature-request

Would be nice to finish removing the Ruby dependency from the builds. http://www.hanselman.com/blog/ExploringWyamANETStaticSiteContentGenerator.aspx

help wanted
documentation

Hi, I'm using ICloneable in my unit tests, and I'm getting false positives. Any help is appreciated. I'm using the latest NSubstitute from NuGet. // Both parent and child implement...

If I try to inspect a substitute's properties in the debugger I get the message 'The function evaluation requires all threads to run'. If I then click the 'Refresh' button...

feature-request