-
Notifications
You must be signed in to change notification settings - Fork 5
/
karma.conf.js
54 lines (52 loc) · 1.43 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
53
54
module.exports = function(config) {
config.set({
basePath: '',
singleRun: true,
frameworks: [
'jasmine',
'webpack'
],
client: {
jasmine: {
random: false
}
},
files: [
'test/karma.js'
],
preprocessors: {
'test/karma.js': ['webpack'],
},
browsers: ['CustomChromiumHeadless'], // ChromeHeadless | Chrome
customLaunchers: {
CustomChromiumHeadless: {
base: 'ChromiumHeadless',
flags: ['--no-sandbox', '--disable-software-rasterizer --disable-dev-shm-usage']
}
},
reporters: [
'spec', // https://github.com/mlex/karma-spec-reporter
'coverage', // https://github.com/karma-runner/karma-coverage
],
specReporter: {
maxLogLines: 5,
suppressErrorSummary: true,
suppressFailed: false,
suppressPassed: false,
suppressSkipped: true,
showSpecTiming: true
},
coverageReporter: {
dir: 'coverage',
subdir: '.',
reporters: [
{type: 'text-summary'},
{type: 'html'}
]
},
webpack: require('./test/webpack.config'),
webpackMiddleware: {
logLevel: 'error'
},
});
};