You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using nunit 3.9.0 and MiniCover (btw really appreciate the work), I am seeing a weird situation where using statement appears to break coverage. Another slightly odd behavior I get is that the test source files are included in the coverage results.
With these tests:
[Test]
public void Test()
{
var stream = new MemoryStream();
stream.Dispose();
}
[Test]
public void TestUsing()
{
using(var stream = new MemoryStream())
{
}
}
Report shows Test() lines are covered, but TestUsing() lines are not. Any tests that follow TestUsing() are also not covered, and the source code of classes only exercised by those tests are not covered.
Calling Dispose() directly does not seem to cause this result.
The text was updated successfully, but these errors were encountered:
Using nunit 3.9.0 and MiniCover (btw really appreciate the work), I am seeing a weird situation where using statement appears to break coverage. Another slightly odd behavior I get is that the test source files are included in the coverage results.
With these tests:
Report shows Test() lines are covered, but TestUsing() lines are not. Any tests that follow TestUsing() are also not covered, and the source code of classes only exercised by those tests are not covered.
Calling Dispose() directly does not seem to cause this result.
The text was updated successfully, but these errors were encountered: