From 0408aff4f3b5c0534eee045727863bf76a663f07 Mon Sep 17 00:00:00 2001 From: Simon Brewster Date: Tue, 5 Sep 2017 00:10:05 +0200 Subject: [PATCH 1/2] doc: instructions for generating coverage reports Add instructions for generating code coverage reports to BUILDING.md --- BUILDING.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/BUILDING.md b/BUILDING.md index 805c89a3cdf9bf..01378b532376cb 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -126,6 +126,17 @@ To run the tests: $ make test ``` +To run the tests and generate code coverage reports: + +```console +$ ./configure --coverage +$ make coverage +``` + +This will generate coverage reports for both JavaScript and C++ tests (if you +only want to run the JavaScript tests then you do not need to run the first +command `./configure --coverage`). + To build the documentation: This will build Node.js first (if necessary) and then use it to build the docs: From 1a560f128b813d907b377aad093a779ace471ac0 Mon Sep 17 00:00:00 2001 From: Simon Brewster Date: Tue, 5 Sep 2017 10:58:30 +0200 Subject: [PATCH 2/2] doc: Document make coverage-clean --- BUILDING.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/BUILDING.md b/BUILDING.md index 01378b532376cb..8bf3d79cd586ae 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -137,6 +137,14 @@ This will generate coverage reports for both JavaScript and C++ tests (if you only want to run the JavaScript tests then you do not need to run the first command `./configure --coverage`). +The `make coverage` command downloads some tools to the project root directory +and overwrites the `lib/` directory. To clean up after generating the coverage +reports: + +```console +make coverage-clean +``` + To build the documentation: This will build Node.js first (if necessary) and then use it to build the docs: