Coder Social home page Coder Social logo

nsubstitute.verify.that's People

Contributors

ben-intercede avatar benagain avatar

Stargazers

 avatar  avatar

Watchers

 avatar

nsubstitute.verify.that's Issues

TypeLoadException for ArgumentSpecificationQueue

I use FluentAssertions 5.6 and NSubstitute 4.1, but there is exception about type loading.

System.TypeLoadException: Could not load type 'NSubstitute.Core.Arguments.ArgumentSpecificationQueue' from assembly 'NSubstitute, Version=4.1.0.0, Culture=neutral, PublicKeyToken=92dd2e9066daa5ca'.
at NSubstitute.Verify.That[T](Action`1 action)

FileLoadException when running tests on v2.0.0

Hi, I have recently stumbled across this project, and was very keen to try applying FluentAssertions to NSubstitute verifications, but I am getting the following error when I try to run my tests:

System.IO.FileLoadException : Could not load file or assembly 'NSubstitute, Version=3.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. 
The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

I have tried adding assembly binding redirects for NSubstitute as follows:

<dependentAssembly>
  <assemblyIdentity name="NSubstitute" publicKeyToken="92dd2e9066daa5ca" culture="neutral" />
  <bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0" />
</dependentAssembly>

I am using NSubstitute 4.2.0 and FluentAssertions 5.7.0 with NUnit 3.12.0, and my application and tests are all based on .NET Framework 4.7.2. All my tests that don't use the Verify.That code pass, and if I rewrite my failing tests to not use Verify.That either then they pass.

Is there anything obvious that I am missing?

Add some doc to Readme

At least a minimal example on how the library is intended to be used as a quick-starter.

You have a reference in code, but that is not enough. Here is a good doc guide IMHO: https://diataxis.fr/

Not compatible with FluentAssertions 5.0+

Hi there, I'm trying to use your library with .net core 2.1 project that depends on FluentAssertions 5.0+ and it looks like it just causes the test to fail 100% of the time with NSubstitute thinking there's no matching calls.

However if I bring the Verify class into the project it seems to work perfectly fine. Feels like a weird .net dependency issue.

Are there any plans to update to 5.0+ of FluentAssertions?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.