From 1a54fc6c9fd878b7944de5b236f7603715f93653 Mon Sep 17 00:00:00 2001 From: Michael Barrett Date: Sun, 6 Mar 2016 21:49:16 +0000 Subject: [PATCH] refactor(coverage): refactor code coverage generation --- .gitignore | 1 + .travis.yml | 3 +-- package.json | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 3c3629e..ba2a97b 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ node_modules +coverage diff --git a/.travis.yml b/.travis.yml index ffa8469..0dd2c3c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -22,7 +22,6 @@ script: - npm run sa after_script: - - istanbul cover ./node_modules/mocha/bin/_mocha --report lcovonly -- -R spec + - npm run cover - cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js - cat ./coverage/lcov.info | ./node_modules/codeclimate-test-reporter/bin/codeclimate.js - - rm -rf ./coverage diff --git a/package.json b/package.json index 5273286..2ddccb6 100644 --- a/package.json +++ b/package.json @@ -4,6 +4,7 @@ "description": "Parse a human readable time string into a time based value", "main": "index.js", "scripts": { + "cover": "istanbul cover ./node_modules/mocha/bin/_mocha --report lcovonly -x test.js test.js", "dev": "watch 'clear; npm test -s;' ./ -d", "sa": "jshint index.js && jscs index.js", "test": "mocha test.js"