diff --git a/.travis.yml b/.travis.yml index bd38d197f..7b92cf25b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,3 +16,8 @@ cache: branches: only: - master +before_script: + - nvm install stable + - npm run lint + - nvm use $TRAVIS_NODE_VERSION + - npm run unit-tests diff --git a/package.json b/package.json index cb40ccac8..178f72a81 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,9 @@ }, "scripts": { "prepublish": "babel --out-dir build lib", - "test": "tape -r babel-register test/*.js && eslint lib test" + "lint": "eslint lib test", + "unit-tests": "tape -r babel-register test/*.js", + "test": "npm run unit-tests && npm run lint" }, "repository": { "type": "git",