Closed aholachek closed 4 years ago
Here's an example coverage.json file that I think demonstrates the problem. The first entry is "https://www.reddit.com/"
, which is filtered out of the array on line 98 of coverage.ts
, causing coverageIndex
to shift one back.
Here is the visualization that i get from this coverage file before the fix:
And after the fix:
Thanks for the contribution
Hi, I very well might be missing something, but I believe using a
filter
to remove coverage entries with an empty "pathParts" array can interfere with the use ofcoverageIndex
to index into thecoverages
array on line 110 of coverage.ts.Before I made this change, I was getting inconsistent and sometimes surprising coverage visualizations. After I made the change, the coverage visualizations aligned more closely with what I was seeing in the chrome devtools.