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

**Is your feature request related to a problem? Please describe.** NSubstitute is a great library and is one the preferred test tool for mocks, not least because of the Moq...

This change allows NSubstitute to support Capture.In functionality

Hi, Nuget have feature of deprication + unlist for nuget packages versions ![image](https://github.com/nsubstitute/NSubstitute/assets/12048821/7f22398e-046d-407a-ba8e-3c98afaf17f9) Versions that I propose to unlist + deprecate following package versions: 1) All versions below 1.0.0 2)...

changes: - Update build project to .NET 8 note: no changes in product, no need to release new nuget package

**Describe the bug** I'm trying to test memory leaks on my library, but NSubstitute retains reference to call arguments (even after `ClearReceivedCalls`). This makes it impossible to test memory leaks...

**Question** Hello. I am trying to mock out this method so that any time it is called the Func is invoked and T is returned. `T New(Func instantiate) where T...

question

**Question** I've been using NSubstitute for a very long time - it's how I was introduced to mocking in .NET, as part of TDD practices. As part of my current...

**Describe the bug** I am suspecting that something is not working well with argument matchers that matches structs with a field with non-default value initializer. Maybe I am doing something...

bug

**Is your feature request related to a problem? Please describe.** A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] Regardless future changes of...

**Describe the bug** When using Arg.Is(expression), depending on the expression, the code can't compile. The compiler error is Error CS0121 : The call is ambiguous between the following methods or...