Skip to content

Commit

Permalink
[Tests] run nyc on all tests; use tape runner
Browse files Browse the repository at this point in the history
  • Loading branch information
ljharb committed May 2, 2021
1 parent e696780 commit 4fdd7e8
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 10 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ lib-cov

# Coverage directory used by tools like istanbul
coverage/
.nyc_output/

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt
Expand Down
9 changes: 9 additions & 0 deletions .nycrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"all": true,
"check-coverage": false,
"reporter": ["text-summary", "text", "html", "json"],
"exclude": [
"coverage",
"test"
]
}
14 changes: 4 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,10 @@
"scripts": {
"prepublishOnly": "safe-publish-latest",
"prepublish": "not-in-publish || npm run prepublishOnly",
"pretest": "npm run --silent lint && npm run --silent coverage",
"test": "npm run --silent tests-only",
"pretest": "npm run lint",
"test": "npm run tests-only",
"posttest": "aud --production",
"tests-only": "node --es-staging test",
"coverage": "npm run --silent cover:clean && npm run --silent cover:istanbul && npm run --silent cover:check",
"cover:clean": "rimraf coverage",
"cover:istanbul": "istanbul cover test --report html",
"cover:check": "istanbul check",
"cover:covert": "covert test",
"tests-only": "nyc tape 'test/**/*.js'",
"lint": "eslint ."
},
"repository": {
Expand All @@ -51,9 +46,8 @@
"devDependencies": {
"@ljharb/eslint-config": "^17.2.0",
"aud": "^1.1.2",
"covert": "^1.1.1",
"eslint": "^7.11.0",
"istanbul": "^1.0.0-alpha.2",
"nyc": "^10.3.2",
"rimraf": "^2.7.1",
"safe-publish-latest": "^1.1.4",
"tape": "^5.0.1"
Expand Down

0 comments on commit 4fdd7e8

Please sign in to comment.