diff --git a/.eslintignore b/.eslintignore new file mode 100644 index 0000000..404abb2 --- /dev/null +++ b/.eslintignore @@ -0,0 +1 @@ +coverage/ diff --git a/.nycrc b/.nycrc new file mode 100644 index 0000000..1826526 --- /dev/null +++ b/.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" + ] +} diff --git a/package.json b/package.json index 3916089..57acbd9 100644 --- a/package.json +++ b/package.json @@ -9,8 +9,8 @@ "prepublish": "safe-publish-latest", "pretest": "npm run lint", "lint": "eslint .", - "tests-only": "node test", - "posttests-only": "node -e \"require('es5-shim'); require('es6-shim'); require('./test');\"", + "tests-only": "nyc tape 'test/**/*.js'", + "tests:shims": "nyc tape --require=es5-shim --require=es5-shim 'test/**/*.js'", "test": "npm run tests-only", "posttest": "npx aud --production" }, @@ -44,6 +44,7 @@ "es6-shim": "^0.35.5", "eslint": "^6.8.0", "for-each": "^0.3.3", + "nyc": "^10.3.2", "object-inspect": "^1.7.0", "safe-publish-latest": "^1.1.4", "tape": "^5.0.0-next.5"