Skip to content
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

Coverage info doesn't match 100% with llvm-cov's report #3

Open
dnaka91 opened this issue Jun 20, 2023 · 1 comment
Open

Coverage info doesn't match 100% with llvm-cov's report #3

dnaka91 opened this issue Jun 20, 2023 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@dnaka91
Copy link
Owner

dnaka91 commented Jun 20, 2023

Describe the bug

I noticed that the displayed coverage isn't always the same as seen in the regular llvm-cov output. Already fixed partially locally, but especially the regions for missing instantiations are not correct.

Expected behavior

The report should always match 100% with what is visible in llvm-cov. Some parts may of course be different in how they're displayed, but the information about what lines are not covered should always be correct.

To reproduce

No response

What operating system are you using?

None

Terminal output

No response

Additional context

This will need some more tinkering, as I didn't find the pattern in the JSON data yet, that would allow me to match the instantiation messages 100% with llvm-cov.

But at least the basic coverage data is already fixed, and a new version will be released soon.

@dnaka91 dnaka91 added the bug Something isn't working label Jun 20, 2023
@dnaka91 dnaka91 self-assigned this Jun 20, 2023
@dnaka91
Copy link
Owner Author

dnaka91 commented Jun 22, 2023

Okay, partially solved this.

The coverage should now be correct in the latest release. The problem was that there are two layers of coverage. Overall coverage areas per file, and then function invocations.

Inside a covered area (on the file level), there can still be the lack of a function call. Technically not even a function call but any form of invocation. For example, branch in a match statement that was never triggered. These were still marked as covered in my report.

Now those are correctly reported, overriding the color of a covered area.

But still struggling to find a pattern that matches exactly the llvm-cov report when it comes to displaying missing invocations. The LLVM code didn't give much clue, as the reporting code operates on different data than in the JSON output.

So I'll have to just look at different report, compare them and look for anything in the raw JSON data that could give me some insight...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant