Skip to content

Commit

Permalink
Merge pull request #473 from jprichardson/ci
Browse files Browse the repository at this point in the history
Update & Optimize CI configs
  • Loading branch information
jprichardson committed Jul 31, 2017
2 parents 9b5718c + 5435252 commit ab2fae9
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 10 deletions.
16 changes: 9 additions & 7 deletions .travis.yml
@@ -1,16 +1,18 @@
sudo: false
language: node_js
node_js:
- "4"
- "5"
- "6"
- "7"
matrix:
include:
- node_js: "4"
- node_js: "5"
# We run both lint and unit on Node 6
- node_js: "6"
env: TEST_SUITE=test
- node_js: "7"
env: TEST_SUITE=lint
# We run coverage on Node 8
- node_js: "8"
env: TEST_SUITE=coverage
env:
- TEST_SUITE=unit
script: npm run-script $TEST_SUITE
after_success:
- if [ $TEST_SUITE = lint ]; then npm run coveralls; fi
- if [ $TEST_SUITE = coverage ]; then npm run coveralls; fi
5 changes: 3 additions & 2 deletions appveyor.yml
Expand Up @@ -4,6 +4,7 @@ environment:
# node.js
- nodejs_version: "4"
- nodejs_version: "6"
- nodejs_version: "8"

# Install scripts. (runs after repo cloning)
install:
Expand All @@ -18,8 +19,8 @@ test_script:
# Output useful info for debugging.
- node --version
- npm --version
# run tests
- npm test
# run only unit tests; travis does the linting
- npm run unit

# Don't actually build.
build: off
2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -55,7 +55,7 @@
"main": "./lib/index",
"scripts": {
"coverage": "istanbul cover -i 'lib/**' -x '**/__tests__/**' test.js",
"coveralls": "npm run coverage && coveralls < coverage/lcov.info",
"coveralls": "coveralls < coverage/lcov.info",
"lint": "standard && standard-markdown",
"test-find": "find ./lib/**/__tests__ -name *.test.js | xargs mocha",
"test": "npm run lint && npm run unit",
Expand Down

0 comments on commit ab2fae9

Please sign in to comment.