Skip to content

Commit

Permalink
[Tests] run nyc on all tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ljharb committed Dec 2, 2020
1 parent c79aee4 commit a03b699
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 5 deletions.
1 change: 1 addition & 0 deletions .eslintignore
@@ -0,0 +1 @@
coverage/
3 changes: 3 additions & 0 deletions .gitignore
Expand Up @@ -18,3 +18,6 @@ node_modules
npm-shrinkwrap.json
package-lock.json
yarn.lock

coverage/
.nyc_output/
13 changes: 13 additions & 0 deletions .nycrc
@@ -0,0 +1,13 @@
{
"all": true,
"check-coverage": false,
"reporter": ["text-summary", "text", "html", "json"],
"lines": 86,
"statements": 85.93,
"functions": 82.43,
"branches": 76.06,
"exclude": [
"coverage",
"test"
]
}
8 changes: 3 additions & 5 deletions package.json
Expand Up @@ -28,8 +28,8 @@
"@ljharb/eslint-config": "^17.2.0",
"aud": "^1.1.2",
"auto-changelog": "^2.2.0",
"covert": "^1.1.1",
"eslint": "^7.7.0",
"nyc": "^10.3.2",
"safe-publish-latest": "^1.1.4",
"tape": "^5.0.1"
},
Expand All @@ -43,11 +43,9 @@
"scripts": {
"prepublish": "safe-publish-latest",
"pretest": "npm run lint",
"tests-only": "node test",
"test": "npm run tests-only && npm run coverage -- --quiet",
"tests-only": "nyc tape 'test/**/*.js'",
"test": "npm run tests-only",
"posttest": "npx aud --production",
"coverage": "covert test/index.js",
"lint": "eslint .",
"version": "auto-changelog && git add CHANGELOG.md",
"postversion": "auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""
},
Expand Down

0 comments on commit a03b699

Please sign in to comment.