Background
I am working on a project with C# .NET, and I've just added a new unit test project to my solution in Visual Studio. The way that I always have been doing this is:
- Create a new unit test project.
- Have that project include a reference to the project under test.
- Just include (
using
) the project.
I guess the other way you could do it would be...
- Create a new unit test project.
- Have that project include a reference to the project under test.
- Make the unit test project share a namespace with the project under test.
Question
Is there an accepted way of doing this for projects in the .NET world, or, is this just an opinion and there is nothing more to it?
MethodName_StateUnderTest_ExpectedBehavior()
, and I'm sure you could find suitable non-conflicting names for the test classes. The real question is: do you really want those types showing up in your intellisense?