ninject / Ninject.MockingKernel

Extension for Ninject aiding testability in Moq, NSubstitute, and FakeItEasy
http://ninject.org/
Other
62 stars 25 forks source link

NSubstitute is on a current version of 1.8.1 #19

Closed apolfj123 closed 6 years ago

apolfj123 commented 9 years ago

I would like to use both Ninject.MockingKernel and NSubstitute version 1.8.1. Currently the NSubstitute extension for Ninject.MockingKernel is not compatible with NSubstitute version 1.8.1

kevinkuszyk commented 9 years ago

I think you should be able to use a binding redirect to use the latest NSub:

<runtime>
  <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
   <dependentAssembly>
      <assemblyIdentity name="NSubstitute" publicKeyToken="92dd2e9066daa5ca" culture="neutral" />
      <bindingRedirect oldVersion="0.0.0.0-1.8.1.0" newVersion="1.8.1.0" />
    </dependentAssembly>
  </assemblyBinding>
</runtime>