Skip to content

Latest commit

 

History

History
29 lines (20 loc) · 1.1 KB

code-coverage.md

File metadata and controls

29 lines (20 loc) · 1.1 KB

Code coverage

Translations: Español, Français, Italiano, 日本語, Português, Русский, 简体中文

Use c8 to compute the code coverage of your tests.

First install c8:

$ npm install --save-dev c8

At its simplest run AVA through c8. In your package.json file:

{
	"scripts": {
		"test": "c8 ava"
	}
}

You may want to exclude the coverage directory from source control. Assuming you're using Git, add the following to your .gitignore file:

coverage