-
Notifications
You must be signed in to change notification settings - Fork 335
vstest.console.exe not detecting data collectors for code coverage #15049
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
@fhnaseer please help here. |
@davidkeaveny Can you run it with Also, did you get vstest.console.exe from nuget package or somewhere else? |
@fhnaseer at this point I'm assuming I'm attaching the diagnostic logs. debug.datacollector.25-04-16_08-44-10_77151_5.txt |
@davidkeaveny You are using Professional edition of Visual Studio. Code Coverage components are not shipped with Professional edition. Please download this package => https://www.nuget.org/packages/Microsoft.TestPlatform/17.13.0 |
@fhnaseer the good news is that I can now see a If I change my command to use |
I am not sure if But you can skip
Also, you can use dotnet test and then you do not need to download microsoft.testplatform nuget package.
|
I am attempting to run code coverage on a .NET Framework 4.7.2 application using
vstest.console.exe
, but when I run the tests from the command line, the tests themselves pass but a coverage report is not generated.My test project file looks like this:
and if I run the following command from the solution root folder then all tests pass:
All good so far; however, if I then change the command to run code coverage:
So I then go and create
CodeCoverage.runsettings
as follows:and run my new command:
so no change at all, whether or not I specify the
.runsettings
file.How can I get coverage to run? Should I be referencing
coverlet.collector
at all, or is that .NET Core-only assembly?The text was updated successfully, but these errors were encountered: