code & chips

general programming stuff…

Posts Tagged ‘Tests

Delay/Test Signing Assemblies and Testing

leave a comment »

Note to self:

When delay/test signing your assemblies remember to run the follwing command before running unit tests:

sn -Vr myAssembly.dll

All my unit tests were failing because the .NET framework – and so the test runner – would not allow me to load an assembly that it considered to be tampered.  Delay/Test is essentially tampering, by signing the public key and allocating space for the private key.

So make sure to run the above command to configure the .NET framework to skip strong name verification for the delay/test signed assembly or application.

That was 2 hours wasted…..

Written by Kam

July 31, 2011 at 12:34 am

Posted in Uncategorized

Tagged with ,

Follow

Get every new post delivered to your Inbox.