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
In MTP (MSTest) the IncludeTestAssembly defaults to false. The ask is to make it default to true.
Code coverage of a test assembly has one practical meaning: in a PR, once presented to the reviewer that certain lines are covered, is an indication that the whole build+test+collect+visualize pipeline works.
Test projects will be included by default in the coverage report from version 18.3.x onwards. Default behavior is now same as vstest.console.exe test.dll /EnableCodeCoverage.
Activity
Youssef1313 commentedon Oct 17, 2025
I personally do agree that IncludeTestAssembly is a better default.
In past, there was an ask for coverlet coverlet-coverage/coverlet#618 which I do agree with.
[-][MT] IncludeTestAssembly default to true[/-][+][MTP] IncludeTestAssembly default to true[/+]Youssef1313 commentedon Nov 24, 2025
fhnaseer We will need to update the documentation as well.
fhnaseer commentedon Nov 24, 2025
Test projects will be included by default in the coverage report from version 18.3.x onwards. Default behavior is now same as
vstest.console.exe test.dll /EnableCodeCoverage.fhnaseer commentedon Feb 5, 2026
This change has been reverted due to
dotnet testfailing on linux. dotnet/sdk#52029