mirror of
https://github.com/pebble-dev/clay.git
synced 2026-08-28 04:46:57 -04:00
add threshold reporter and fix travis
This commit is contained in:
+3
-1
@@ -7,7 +7,7 @@
|
|||||||
"example": "example"
|
"example": "example"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test-travis": "./node_modules/karma/bin/karma start ./test/karma.conf.js --single-run",
|
"test-travis": "./node_modules/karma/bin/karma start ./test/karma.conf.js --single-run --browsers chromeTravisCI",
|
||||||
"test": "./node_modules/karma/bin/karma start ./test/karma.conf.js --no-single-run",
|
"test": "./node_modules/karma/bin/karma start ./test/karma.conf.js --no-single-run",
|
||||||
"build": "gulp"
|
"build": "gulp"
|
||||||
},
|
},
|
||||||
@@ -33,6 +33,7 @@
|
|||||||
"eslint-config-pebble": "^1.2.0",
|
"eslint-config-pebble": "^1.2.0",
|
||||||
"eslint-plugin-standard": "^1.3.1",
|
"eslint-plugin-standard": "^1.3.1",
|
||||||
"gulp-autoprefixer": "^3.1.0",
|
"gulp-autoprefixer": "^3.1.0",
|
||||||
|
"gulp-htmlmin": "^1.3.0",
|
||||||
"gulp-sass": "^2.1.1",
|
"gulp-sass": "^2.1.1",
|
||||||
"gulp-sourcemaps": "^1.6.0",
|
"gulp-sourcemaps": "^1.6.0",
|
||||||
"karma": "^0.13.19",
|
"karma": "^0.13.19",
|
||||||
@@ -42,6 +43,7 @@
|
|||||||
"karma-mocha": "^0.2.1",
|
"karma-mocha": "^0.2.1",
|
||||||
"karma-mocha-reporter": "^1.1.5",
|
"karma-mocha-reporter": "^1.1.5",
|
||||||
"karma-source-map-support": "^1.1.0",
|
"karma-source-map-support": "^1.1.0",
|
||||||
|
"karma-threshold-reporter": "^0.1.15",
|
||||||
"mocha": "^2.3.4",
|
"mocha": "^2.3.4",
|
||||||
"watchify": "^3.7.0"
|
"watchify": "^3.7.0"
|
||||||
},
|
},
|
||||||
|
|||||||
+16
-1
@@ -45,7 +45,7 @@ module.exports = function(config) {
|
|||||||
// test results reporter to use
|
// test results reporter to use
|
||||||
// possible values: 'dots', 'progress'
|
// possible values: 'dots', 'progress'
|
||||||
// available reporters: https://npmjs.org/browse/keyword/karma-reporter
|
// available reporters: https://npmjs.org/browse/keyword/karma-reporter
|
||||||
reporters: ['progress', 'mocha', 'coverage'],
|
reporters: ['progress', 'mocha', 'coverage', 'threshold'],
|
||||||
|
|
||||||
// optionally, configure the reporter
|
// optionally, configure the reporter
|
||||||
coverageReporter: {
|
coverageReporter: {
|
||||||
@@ -56,6 +56,13 @@ module.exports = function(config) {
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|
||||||
|
thresholdReporter: {
|
||||||
|
statements: 100,
|
||||||
|
branches: 100,
|
||||||
|
functions: 100,
|
||||||
|
lines: 100
|
||||||
|
},
|
||||||
|
|
||||||
// web server port
|
// web server port
|
||||||
port: 9876,
|
port: 9876,
|
||||||
|
|
||||||
@@ -74,6 +81,14 @@ module.exports = function(config) {
|
|||||||
// available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
|
// available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
|
||||||
browsers: ['Chrome'],
|
browsers: ['Chrome'],
|
||||||
|
|
||||||
|
// set via the command line
|
||||||
|
customLaunchers: {
|
||||||
|
chromeTravisCI: {
|
||||||
|
base: 'Chrome',
|
||||||
|
flags: ['--no-sandbox']
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
// Continuous Integration mode
|
// Continuous Integration mode
|
||||||
// if true, Karma captures browsers, runs the tests and exits
|
// if true, Karma captures browsers, runs the tests and exits
|
||||||
singleRun: true,
|
singleRun: true,
|
||||||
|
|||||||
Reference in New Issue
Block a user