Quick n' dirty way to visualize test coverage of files you've changed since your git branch started.
git
- a *nix with
paste
- a project that is configured to use Jest for testing and coverage reports
npm
oryarn
-
Install with
npm
oryarn
:yarn add --dev @axioscode/diff-cover
-
Run:
yarn run diff-cover
To change the base branch for coverage comparison, set the COVER_BASE
environment variable:
COVER_BASE=stable yarn run diff-cover