Skip to content

fix open cover reporter so that it uses unique ids over multiple modules #20

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

Merged
merged 1 commit into from
Mar 27, 2018

Conversation

corinblaikie
Copy link

The open cover output doesn't work with report generator as it has the same uid values for different files over multiple modules.

<ModuleName>Module.A</ModuleName>
<Files>
<File uid="1" fullPath="C:\code\testproject\src\Module.A\Example.A.cs" />
...
<ModuleName>Module.B</ModuleName>
<Files>
<File uid="1" fullPath="C:\code\testproject\src\Module.B\Example.B.cs" />

instead of

<ModuleName>Module.A</ModuleName>
<Files>
<File uid="1" fullPath="C:\code\testproject\src\Module.A\Example.A.cs" />
...
<ModuleName>Module.B</ModuleName>
<Files>
<File uid="2" fullPath="C:\code\testproject\src\Module.B\Example.B.cs" />

@coveralls
Copy link

Pull Request Test Coverage Report for Build #33

  • 0 of 0 (NaN%) changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 81.215%

Totals Coverage Status
Change from base Build #32: 0.0%
Covered Lines: 294
Relevant Lines: 362

💛 - Coveralls

@tonerdo
Copy link
Collaborator

tonerdo commented Mar 27, 2018

@corinblaikie thanks!!! I'm curious though, is this the only fix needed to get it working with ReportGenerator. Can you please post a screenshot of report generator showing a coverlet output, didn't test it myself so will love to see it

@corinblaikie
Copy link
Author

corinblaikie commented Mar 27, 2018

ReportGenerator seems to work with the coverlet open cover xml:

image

Copy link
Collaborator

@tonerdo tonerdo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@tonerdo tonerdo merged commit 7e0bf3c into coverlet-coverage:master Mar 27, 2018
@corinblaikie
Copy link
Author

Thanks, could you please trigger a new release with this commit in it?

@tonerdo
Copy link
Collaborator

tonerdo commented Mar 28, 2018

I'm following a weekly release cycle. This commit will be included in the NuGet package release next Monday

@tonerdo
Copy link
Collaborator

tonerdo commented Apr 2, 2018

@corinblaikie new release with your changes: https://www.nuget.org/packages/coverlet.msbuild/1.0.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants