Skip to content

Navigation Menu

Sign in
Sign up

Repository files navigation

Test Coverage

Running the Data Collector

The data collector runs the tests and collects the data into an XML file. It can be run by navigating to the test project and then calling:

dotnet test --collect:"XPlat Code Coverage" 

It will generate an XML output file in a TestResults subfolder.

Report Generation

In order to display the results of the tests run in a pretty format, we need to run a report generator. That can be done by navigating to the test project directory and then calling:

reportgenerator -reports:"C:\!Personal\ManagerHelper\ManagerHelperTests\TestResults\<Guid>\coverage.cobertura.xml" -targetdir:"coveragereport" -reporttypes:Html

This will create an HTML page in a coveragereport subfolder.

Resource: https://learn.microsoft.com/en-us/dotnet/core/testing/unit-testing-code-coverage?tabs=windows

About

Cross-platform application used to help me in my day to day activities as a manager. Hopefully this will help others as well, one day.

Topics

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages

AltStyle によって変換されたページ (->オリジナル) /