Test coverage commands.
This directory contains make
rules for running project unit tests and generating test coverage reports.
Usage: make <command> [<ENV_VAR>=<value> <ENV_VAR>=<value> ...]
Runs unit tests and generates a test coverage report.
$ make test-cov
The command supports the following environment variables:
- TESTS_FILTER: file path pattern; e.g.,
.*/blas/base/dasum/.*
. - FAST_FAIL: flag indicating whether to stop running tests upon encountering a test failure.
$ make test-cov TESTS_FILTER='.*/blas/base/dasum/.*'
Opens an HTML test coverage report in a local web browser.
$ make view-cov
Removes coverage artifacts, such as reports and HTML pages.
$ make clean-cov
Runs JavaScript unit tests and generates a test coverage report.
$ make test-javascript-cov
The command supports the following environment variables:
- TESTS_FILTER: file path pattern; e.g.,
.*/blas/base/dasum/.*
. - FAST_FAIL: flag indicating whether to stop running tests upon encountering a test failure.
$ make test-javascript-cov TESTS_FILTER='.*/blas/base/dasum/.*'
Opens an HTML test coverage report in a local web browser.
$ make view-javascript-cov
Removes a JavaScript coverage directory (including all coverage artifacts).
$ make clean-javascript-cov
- Commands supporting a
TESTS_FILTER
environment variable are useful when wanting to glob for test files (e.g., run all tests for a particular package).