I have structured my Tests in Visual Studio like so:
[TestClass]
public class TestContainer
{
[TestClass]
public class MoreSpecificContainer
{
[TestMethod]
public void Test_Should_ReturnSomething()
{
}
}
[TestClass]
public class AnotherSpecificContainer
{
[TestMethod]
public void AnotherTest_Should_ReturnSomething()
{
}
}
}
Sadly, OpenCover (great tool, btw!) is not including the nested TestClass methods in it's coverage. I assume this is because they're nested. If I remove the nested 'MoreSpecificContainer' and 'AnotherSpecificContainer' classes and the test methods are only inside the main 'TestContainer' TestClass, then the tests are run by OpenCover and results are included in the reporting perfectly. Using OpenCover 4.6.166 and ReportGenerator.2.3.2.0
Is there any way that anybody knows of to configure OpenCover to notice the methods inside nested TestClasses?
Thank you, codenewbie