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

Generate coverage for uncovered source files #2892

Merged
merged 1 commit into from
Mar 11, 2017

Conversation

TimvdLippe
Copy link
Contributor

Summary

The coverage tool of Jest did not generate the coverage for files that were not covered at all. E.g. files that are completely untested. The bad news: A lot of commands are left untested and the total coverage is significantly lower than before. The good news: after this change, you can actually see which commands require more tests which others might be able to contribute!

To trigger coverage for all files, the option collectCoverageFrom can be used per jestjs/jest#1211 (comment)

Test plan

Run yarn test and open coverage/lcov-report/index.html in a browser of your preference. Observe that a lot of commands are now showing 0% coverage. The previous coverage report did not include these empty coverage files.

@Daniel15
Copy link
Member

This looks good to me. Thanks!

@Daniel15 Daniel15 merged commit 664b6a4 into yarnpkg:master Mar 11, 2017
@TimvdLippe TimvdLippe deleted the all-coverage branch March 11, 2017 11:10
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.

2 participants