Skip to content

Commit

Permalink
test: exclude write-coverage from coverage report
Browse files Browse the repository at this point in the history
Added a .nyrc configuration file that can be used to configure
test coverage.

Added an exclude rule that removes write-coverage.js from coverage
reports.

Pulled reporter configuration into .nycrc and added an additional
text reporter.

PR-URL: #15194
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
  • Loading branch information
Benjamin Coe authored and MylesBorins committed Sep 11, 2017
1 parent ed81497 commit d4d8da9
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Expand Up @@ -12,6 +12,7 @@
!.gitignore
!.gitkeep
!.mailmap
!.nycrc
!.remarkrc

core
Expand Down
6 changes: 6 additions & 0 deletions .nycrc
@@ -0,0 +1,6 @@
{
"exclude": [
"**/internal/process/write-coverage.js"
],
"reporter": ["html", "text"]
}
2 changes: 1 addition & 1 deletion Makefile
Expand Up @@ -166,7 +166,7 @@ coverage-test: coverage-build
$(NODE) ./node_modules/.bin/istanbul-merge --out \
.cov_tmp/libcov.json 'out/Release/.coverage/coverage-*.json'
(cd lib && .$(NODE) ../node_modules/.bin/nyc report \
--temp-directory "$(CURDIR)/.cov_tmp" -r html \
--temp-directory "$(CURDIR)/.cov_tmp" \
--report-dir "../coverage")
-(cd out && "../gcovr/scripts/gcovr" --gcov-exclude='.*deps' \
--gcov-exclude='.*usr' -v -r Release/obj.target/node \
Expand Down

0 comments on commit d4d8da9

Please sign in to comment.