From 1291323adf4cfe3b6bf0217051ba983d4a59416e Mon Sep 17 00:00:00 2001 From: Ivan Marban Date: Sun, 28 Apr 2019 19:08:56 +0200 Subject: [PATCH] Integrating with coveralls --- .travis.yml | 3 +++ package-lock.json | 34 ++++++++++++++++++++++++++++++++++ package.json | 7 ++++--- 3 files changed, 41 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index 69269a3..881a14a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,3 +11,6 @@ before_install: script: - npm test + +after_success: + - npm run coverage diff --git a/package-lock.json b/package-lock.json index 29729d8..5aac430 100644 --- a/package-lock.json +++ b/package-lock.json @@ -645,6 +645,28 @@ "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" }, + "coveralls": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/coveralls/-/coveralls-3.0.3.tgz", + "integrity": "sha512-viNfeGlda2zJr8Gj1zqXpDMRjw9uM54p7wzZdvLRyOgnAfCe974Dq4veZkjJdxQXbmdppu6flEajFYseHYaUhg==", + "dev": true, + "requires": { + "growl": "~> 1.10.0", + "js-yaml": "^3.11.0", + "lcov-parse": "^0.0.10", + "log-driver": "^1.2.7", + "minimist": "^1.2.0", + "request": "^2.86.0" + }, + "dependencies": { + "minimist": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", + "dev": true + } + } + }, "cp-file": { "version": "6.2.0", "resolved": "https://registry.npmjs.org/cp-file/-/cp-file-6.2.0.tgz", @@ -1974,6 +1996,12 @@ "invert-kv": "^2.0.0" } }, + "lcov-parse": { + "version": "0.0.10", + "resolved": "https://registry.npmjs.org/lcov-parse/-/lcov-parse-0.0.10.tgz", + "integrity": "sha1-GwuP+ayceIklBYK3C3ExXZ2m2aM=", + "dev": true + }, "levn": { "version": "0.3.0", "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", @@ -2018,6 +2046,12 @@ "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=", "dev": true }, + "log-driver": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/log-driver/-/log-driver-1.2.7.tgz", + "integrity": "sha512-U7KCmLdqsGHBLeWqYlFA0V0Sl6P08EE1ZrmA9cxjUE0WVqT9qnyVDPz1kzpFEP0jdJuFnasWIfSd7fsaNXkpbg==", + "dev": true + }, "log-symbols": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-2.2.0.tgz", diff --git a/package.json b/package.json index fbcae5d..bb5eae0 100644 --- a/package.json +++ b/package.json @@ -33,6 +33,7 @@ "license": "MIT", "devDependencies": { "chai": "^4.2.0", + "coveralls": "^3.0.3", "eslint": "^5.16.0", "eslint-config-standard": "^12.0.0", "eslint-plugin-import": "^2.17.2", @@ -51,8 +52,8 @@ "scripts": { "lint": "eslint lib test examples --color", "format": "prettier-standard 'lib/**/*.js' 'test/**/*.js' 'examples/**/*.js'", - "test": "nyc --reporter=text --reporter lcov npm run test:mocha", - "test:mocha": "mocha --exit", - "test:coverage": "nyc --reporter=text --reporter=html npm run test:mocha" + "test": "nyc mocha", + "coverage": "nyc report --reporter=text-lcov | coveralls", + "test:coverage": "nyc --reporter=text --reporter=html mocha" } }