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

fix: Drop coverage produced by nyc --all for files that were tested #1155

Merged
merged 2 commits into from
Aug 2, 2019

Conversation

coreyfarrell
Copy link
Member

Sometimes the coverage data produced by nyc --all is incompatible with
the coverage data produced by actual test runs. This is generally due
to configuration error but results in inconsistent coverage reports or
in some cases causes nyc report to crash. The workaround is
implemented in istanbul-lib-coverage to drop coverage data associated
with nyc --all when coverage data from a test run is found. This
commit tags the coverage data when appropriate so the coverage merge
logic knows what to do.

Fixes #1113, #1124, #1148

Sometimes the coverage data produced by `nyc --all` is incompatible with
the coverage data produced by actual test runs.  This is generally due
to configuration error but results in inconsistent coverage reports or
in some cases causes `nyc report` to crash.  The workaround is
implemented in istanbul-lib-coverage to drop coverage data associated
with `nyc --all` when coverage data from a test run is found.  This
commit tags the coverage data when appropriate so the coverage merge
logic knows what to do.

Fixes istanbuljs#1113, istanbuljs#1124, istanbuljs#1148
This makes the behavior consistent with the real instrumenter which just
provides raw data.
@coveralls
Copy link

Coverage Status

Coverage decreased (-0.005%) to 97.845% when pulling 990bdec on coreyfarrell:annotate-all-cov into 7783284 on istanbuljs:master.

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.

Inconsistent coverage levels between runs with "all"
3 participants