This commit is contained in:
Raoul Snyman 2019-08-27 09:28:34 -07:00
commit c8368a91cf
3 changed files with 12 additions and 6 deletions

View File

@ -17,3 +17,4 @@ include LICENSE
include README.txt include README.txt
include openlp/.version include openlp/.version
include package.json include package.json
include karma.conf.js

View File

@ -26,18 +26,21 @@ module.exports = function(config) {
// source files, that you wanna generate coverage for // source files, that you wanna generate coverage for
// do not include tests or libraries // do not include tests or libraries
// (these files will be instrumented by Istanbul) // (these files will be instrumented by Istanbul)
"display.js": ["coverage"] // "display.js": ["coverage"]
}, },
// 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", "coverage"], reporters: ["dots", "junit"],
// configure the coverateReporter // configure the coverateReporter
coverageReporter: { /* coverageReporter: {
type : "html", type : "html",
dir : "htmlcov/" dir : "htmlcov/"
}, */
junitReporter: {
outputFile: "test-results.xml"
}, },
// web server port // web server port
@ -60,11 +63,11 @@ module.exports = function(config) {
// start these browsers // start these browsers
// available browser launchers: https://npmjs.org/browse/keyword/karma-launcher // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
browsers: ["Firefox"], browsers: ["Chromium"],
// 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: false, singleRun: true,
// Concurrency level // Concurrency level
// how many browser should be started simultaneous // how many browser should be started simultaneous

View File

@ -9,9 +9,11 @@
"dependencies": { "dependencies": {
"jasmine-core": "^2.6.4", "jasmine-core": "^2.6.4",
"karma": "^3.1.4", "karma": "^3.1.4",
"karma-chrome-launcher": "^3.1.0",
"karma-coverage": "^1.1.2", "karma-coverage": "^1.1.2",
"karma-jasmine": "^1.1.0",
"karma-firefox-launcher": "^1.2.0", "karma-firefox-launcher": "^1.2.0",
"karma-jasmine": "^1.1.0",
"karma-junit-reporter": "^1.2.0",
"karma-log-reporter": "0.0.4" "karma-log-reporter": "0.0.4"
}, },
"scripts": { "scripts": {