-
Notifications
You must be signed in to change notification settings - Fork 1
/
karma.conf.js
52 lines (48 loc) · 1.46 KB
/
karma.conf.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/*globals module,process,require */
module.exports = function (config) {
"use strict";
var coverageDebug = true;
config.set({
basePath: '',
frameworks: ['jasmine'],
files: [
"vendor/jquery/dist/jquery.min.js",
"vendor/underscore/underscore-min.js",
'node_modules/es6-module-loader/dist/es6-module-loader.src.js',
'node_modules/systemjs/dist/system.src.js',
'node_modules/systemjs/dist/system-polyfills.js',
"config.js",
"lib/pow-core/pow-core.js",
{pattern: 'test/fixtures/*.*', watched: true, included: false, served: true},
{pattern: 'test/**/*.js', watched: true, included: false, served: true},
"karma.main.js"
],
reporters: ['dots', 'coverage'],
port: 9876,
autoWatch: true,
background: true,
// - Chrome, ChromeCanary, Firefox, Opera, Safari (only Mac), PhantomJS, IE (only Windows)
browsers: process.env.TRAVIS ? ['TravisChrome'] : ['Chrome'],
browserNoActivityTimeout: 15000,
singleRun: false,
reportSlowerThan: 500,
plugins: [
'karma-*'
],
customLaunchers: {
TravisChrome: {
base: 'Chrome',
flags: ['--no-sandbox']
}
},
preprocessors: (process.env.TRAVIS || coverageDebug) ? {"lib/pow-core/*.js": "coverage"} : {},
coverageReporter: {
dir: '.coverage',
reporters: [
// reporters not supporting the `file` property
{type: 'json'},
{type: 'lcov'}
]
}
});
};