Skip to content

Commit c5ad0ae

Browse files
author
tunnckoCore
committed
fix(package): update devDeps, npm scripts, travis, appveyor
1 parent d5c732b commit c5ad0ae

File tree

4 files changed

+46
-17
lines changed

4 files changed

+46
-17
lines changed

.travis.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ language: node_js
44
node_js:
55
- "node"
66
- "6"
7-
- "5"
87
- "4"
98
- "0.12"
109
- "0.10"
@@ -13,10 +12,10 @@ matrix:
1312
fast_finish: true
1413
allow_failures:
1514
- node_js: "4"
16-
- node_js: "0.10"
1715
- node_js: "0.12"
16+
- node_js: "0.10"
1817

1918
notifications:
2019
email: false
2120

22-
after_success: npm run report-coverage
21+
after_success: bash <(curl -s https://codecov.io/bash)

appveyor.yml

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
environment:
2+
matrix:
3+
# node.js
4+
- nodejs_version: "7"
5+
- nodejs_version: "6"
6+
- nodejs_version: "4"
7+
8+
# Install scripts. (runs after repo cloning)
9+
install:
10+
# Get the latest stable version of Node.js or io.js
11+
- ps: Install-Product node $env:nodejs_version
12+
# install modules
13+
- npm install
14+
15+
# Post-install test scripts.
16+
test_script:
17+
# Output useful info for debugging.
18+
- node --version
19+
- npm --version
20+
# run tests
21+
- npm test
22+
23+
# Don't actually build.
24+
build: off

package.json

+19-13
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,16 @@
88
"main": "index.js",
99
"license": "MIT",
1010
"scripts": {
11-
"lint": "standard --verbose",
12-
"pretest": "npm run lint",
13-
"test": "npm run coverage",
14-
"posttest": "npm run lint:coverage",
15-
"coverage": "nyc node test.js",
16-
"lint:coverage": "nyc check-coverage --lines 100 --branches 100 --statements 100 --functions 100",
17-
"report-coverage": "nyc report --reporter=text-lcov | coveralls",
11+
"lint": "standard **/*.js --fix --verbose",
12+
"test": "npm-run-all -s lint test:*",
13+
"test:api": "nyc --reporter lcov node test.js",
14+
"test:report": "nyc report",
1815
"prerelease": "npm test",
1916
"release": "standard-version --sign --no-verify",
20-
"precommit": "git add --all",
21-
"commit": "git-cz"
17+
"git": "npm-run-all -s git:*",
18+
"git:add": "git add --all",
19+
"git:cz": "git-cz",
20+
"commit": "npm-run-all -s test git"
2221
},
2322
"dependencies": {
2423
"dezalgo": "^1.0.3",
@@ -28,12 +27,12 @@
2827
},
2928
"devDependencies": {
3029
"commitizen": "^2.8.6",
31-
"coveralls": "^2.11.12",
3230
"cz-conventional-changelog": "^1.2.0",
3331
"mukla": "^0.4.1",
34-
"nyc": "^8.1.0",
32+
"npm-run-all": "^4.0.2",
33+
"nyc": "^10.1.2",
3534
"pre-commit": "^1.1.3",
36-
"standard": "^8.5.0",
35+
"standard": "^9.0.0",
3736
"standard-version": "^3.0.0"
3837
},
3938
"files": [
@@ -106,5 +105,12 @@
106105
"lint": {
107106
"reflinks": true
108107
}
108+
},
109+
"nyc": {
110+
"check-coverage": true,
111+
"statements": 100,
112+
"functions": 100,
113+
"branches": 100,
114+
"lines": 100
109115
}
110-
}
116+
}

test.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ test('should be able `fn` to return sync result and get it in `cb`', function (d
5959

6060
test('should pass error to `cb` if throws in `fn`', function (done) {
6161
tryCatchCore(function () {
62-
qux // eslint-disable-line no-undef
62+
qux // eslint-disable-line no-undef, no-unused-expressions
6363
return 'foo bar'
6464
}, function cb (err, res) {
6565
test.ifError(!err)

0 commit comments

Comments
 (0)