forked from LaxarJS/laxar
-
Notifications
You must be signed in to change notification settings - Fork 0
/
karma.config.js
47 lines (43 loc) · 1.17 KB
/
karma.config.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
// Karma configuration for LaxarJS core
/* eslint-env node */
const webpackConfig = Object.assign( {}, require('./webpack.config' ) );
delete webpackConfig.entry;
delete webpackConfig.plugins;
webpackConfig.devtool = 'inline-source-map';
module.exports = function(config) {
const browsers = [ 'PhantomJS', 'Firefox' ].concat( [
process.env.TRAVIS ? 'ChromeTravisCi' : 'Chrome'
] );
config.set( {
frameworks: [ 'jasmine' ],
files: [
'polyfills.js',
'lib/*/spec/spec-runner.js'
],
preprocessors: {
'polyfills.js': [ 'webpack', 'sourcemap' ],
'lib/*/spec/spec-runner.js': [ 'webpack', 'sourcemap' ]
},
webpack: webpackConfig,
webpackMiddleware: {
noInfo: true,
quiet: true
},
reporters: [ 'progress', 'junit' ],
junitReporter: {
outputDir: 'karma-output/'
},
port: 9876,
browsers,
customLaunchers: {
ChromeTravisCi: {
base: 'Chrome',
flags: [ '--no-sandbox' ]
}
},
browserNoActivityTimeout: 100000,
singleRun: true,
autoWatch: false,
concurrency: Infinity
} );
};