-
Notifications
You must be signed in to change notification settings - Fork 0
/
karma.conf.js
54 lines (44 loc) · 1020 Bytes
/
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
process.env.NODE_ENV = 'development';
const webpackConfig = require('./webpack.config.js');
webpackConfig.devtool = 'inline-source-map';
module.exports = function karmaConfig(config) {
config.set({
basePath: '',
browsers: ['PhantomJS'],
singleRun: true,
frameworks: ['jasmine'],
files: [
'test/jasmine/index.js',
],
preprocessors: {
'test/jasmine/index.js': ['webpack', 'sourcemap'],
},
plugins: [
'karma-phantomjs-launcher',
'karma-webpack',
'karma-jasmine',
'karma-sourcemap-loader',
'karma-babel-preprocessor',
],
webpack: webpackConfig,
webpackServer: {
noInfo: true,
},
logLevel: config.LOG_INFO,
babelPreprocessor: {
options: {
presets: ['es2015', 'react'],
},
},
webpackMiddleware: {
noInfo: true,
stats: {
colors: true,
version: false,
assets: false,
chunks: false,
chunkModules: false,
},
},
});
};