-
Notifications
You must be signed in to change notification settings - Fork 0
/
karma.conf.js
52 lines (51 loc) · 1.55 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
const webpack = require('webpack');
module.exports = function (config) {
config.set({
browsers: ['PhantomJS'],
singleRun: true,
frameworks: ['jasmine', 'es6-shim'],
files: [
'tests.webpack.js'
],
preprocessors: {
'tests.webpack.js': ['webpack', 'sourcemap']
},
reporters: ['dots'],
webpack: {
devtool: 'inline-source-map',
resolve: {
extensions: [ '', '.js', '.jsx' ]
},
module: {
loaders: [
{
test: /\.(js|jsx)$/,
exclude: /node_modules/,
loaders: ['babel']
},
{
test: /\.less$/,
exclude: /node_modules/,
loaders: ['style', 'css', 'postcss-loader', 'less']
},
{
test: /\.css$/,
loader: 'style!css?modules'
},
{
test: /\.html$/,
exclude: /node_modules/,
loader: 'file'
},
{
test: /\.jpe?g$|\.gif$|\.png$|\.svg$|\.woff2?$|\.ttf$|\.wav$|\.mp3$|\.eot$|\.json$/,
loader: 'file'
}
]
}
},
webpackServer: {
noInfo: true
}
});
};