Search code examples
c#unit-testingasp.net-identity

in unit testing it gives this error message


System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.AspNet.Identity.EntityFramework, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies.
The system cannot find the file specified.WRN: Assembly binding logging is turned OFF.

I checked the version for Microsoft.AspNet.Identity.EntityFramework and its dependencies all are in same version. what is this error pointing towards? It also says...

"log attempting download of new URL ........Microsoft.AspNet.Identity.EntityFramework/Microsoft.AspNet.Identity.EntityFramework.exe"

which is not there. what does it mean?


Solution

  • Try below fix as it worked for me..

    for 64 bit VS-> Test->Test Settings ->Default Process Architecture ->64 and Must Rebuild

    for 32 bit VS-> Test->Test Settings->Default Process Architecture ->86 and Must Rebuild

    Hope it helps.