I would like my Core assembly to not expose a certain class and I would still like to be able to test it. How can I do that ?
InternalsVisibleTo attribute to the rescue!
Just add:
[assembly:InternalsVisibleToAttribute("UnitTestAssemblyName")]
to your Core classes AssemblyInfo.cs file
See Friend Assemblies (C# Programming Guide) for best practices.
1.4m articles
1.4m replys
5 comments
57.0k users