I'm starting a project which is broken up over multiple VS projects and I was planning on having separate testing projects for each of the projects, so I'd have a solution like this:
- Project1
- Project1.Test
- Project2
- Project2.Test
There are some internal
classes which I want to have tested. So I used Visual Studio 2008 (SP1) to generate the test stubs in my test project and added the InternalsVisibleTo
. But I get a red squiggly line under the internal class. If I compile I get a successful build, and looking at the test method the red squiggles are gone.
But if I tough the file the squiggles come back and I have no intellisense on the internal class.
The internal
is within Project1 and the test is within Project1.Test. For completeness I decided to do the exact same manner of generating the test method but this time into Project2.Test, and this time it's shown to be completely working. I don't get red squiggles, I get intellisense, everything.
I've tried deleting Project1.Test and recreating the test method, everything I can think of, but no matter what I do I can't get the internal to be completely visible within its paired Test project, only in the one which is designed to be for another project.
It's doing my nut that it's not working!