Got 2 assemblies Company.BusinessLogic
and Company.Tests
.
Company.Tests
got reference to Company.BusinessLogic
.
Need to test internal stuff in BusinessLogic
from test project, so added into Business project AssemblyInfo.cs
following line:
[assembly: InternalsVisibleTo("Company.Tests")]
But I get build error:
Error 134 Friend assembly reference 'Company.Tests' is invalid. Strong-name signed assemblies must specify a public key in their InternalsVisibleTo declarations. C:..\Company.BusinessLogic\AssemblyInfo.cs 61 31 Company.BusinessLogic
I do not want to sign assemblies, because BusinessLogic
got a lot of references to other unsigned assemblies.
The MSDN states, that InternalsVisibleTo
should work when both assemblies are signed or both are unsigned (under Remarks and Examples sections):
If both assemblies are unsigned, the assemblyName argument consists of the name of the friend assembly, specified without a directory path or file name extension.
Using: .NET: 4.5.2, Visual Studio 2013 Ultimate
How can I fix this error?