Tuesday, June 12

InternalsVisibleToAttribute, Unit Testing and Strong Names

I previously posted about using the InternalsVisibleTo attibute for testing with NUnit.

I've had some problems building this with a stronly named assembly. I found the following post on Kent Boogaart's blog that describes how you should change the code in your assemblyinfo.cs file as follows:

[assembly: InternalsVisibleTo("Company")]

to

[assembly: InternalsVisibleTo("Company, PublicKey=xxxxxxxxxxxxxxxx")]

No comments: