DotCover Cobertura or OpenCover XML

Viewed 158

I have a dotcover coverage report generated using dotcover.exe. I want to integrate the report in Jenkins and show the coverage. How can I generate a cobertura or openclover xml from it?

1 Answers

You can use ReportGenerator for that.

First, install reportgenerator as dotnet global tool:

dotnet tool install --global dotnet-reportgenerator-globaltool

Second, dotCover report should be in DetailedXML format, it has file paths that needed in Cobertura.

Then, run reportgenerator to convert to desired format, like:

reportgenerator -reports:./dotCover.Output.xml -targetdir:. -reporttypes:Cobertura

As a result, you'll have Cobertura.xml file.

Related