Configuring code coverage tools
In this recipe, you will learn how to configure the code coverage tools istanbul and karma using npm.
istanbul is a good JavaScript code coverage tool that computes statement, line, function, and branch coverage. It supports all JavaScript coverage use cases including unit tests, server-side functional tests, and browser tests. For more details, you can visit the following website:
https://github.com/gotwarlost/istanbul
karma is a test runner that generates a code coverage report using istanbul. For more details, you can visit the following website:
https://github.com/karma-runner/karma-coverage
npm is the package manager for JavaScript. It comes with Node.js. Node.js is an open source server-side and networking ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access