-
Notifications
You must be signed in to change notification settings - Fork 5
/
karma.config.js
47 lines (45 loc) · 1.22 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
const webpackConfig = require("./webpack.config.js");
const browserMode = false;
module.exports = config => {
config.set({
basePath: ".",
client: {
captureConsole: !!browserMode
},
frameworks: ["jasmine"],
reporters: ["mocha"],
port: 9876,
colors: true,
logLevel: browserMode ? config.LOG_DEBUG : config.LOG_DISABLE,
autoWatch: false,
browsers: browserMode ? ["Chrome"] : ["PhantomJS"],
singleRun: !browserMode,
autoWatchBatchDelay: 300,
webpack: webpackConfig,
files: [
"./build/vendor.bundle.js",
"./js/test_config.js",
"./node_modules/jquery/dist/jquery.min.js",
"./node_modules/angular-sortable-view/src/angular-sortable-view.js",
"./vendor/ol-debug.js",
"./partials/standaloneConfig.js",
"./build/app.bundle.js",
"./app/**/*.html",
"./node_modules/angular-mocks/angular-mocks.js",
"./app/**/*.spec.js"
],
preprocessors: {
"./app/**/*.spec.js": ["babel"],
"./js/app.bundle.js": ["webpack"],
"./app/**/*.html": ["ng-html2js"]
},
babelPreprocessor: {
options: {
presets: ["react", "es2015", "stage-0"]
}
},
webpackMiddleware: {
noInfo: true
}
});
};