-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathkarma.conf.js
97 lines (89 loc) · 2.31 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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
// an example karma.conf.js
module.exports = function (config) {
"use strict";
var webpack = require("webpack");
config.set({
preprocessors: {
"src/Core/Test/TestRunner.js": ['webpack' , 'sourcemap']
},
plugins: [
'karma-phantomjs-launcher',
'karma-chrome-launcher',
'karma-firefox-launcher',
'karma-coverage',
'karma-mocha',
'karma-chai',
'karma-webpack',
'karma-sourcemap-loader'
],
webpack: {
output: {
path: __dirname + "/base/src",
publicPath: "/base/src",
filename: 'test-bundle.js'
},
amd: {
jquery: true,
underscore: true,
moment: true,
rsvp: true,
indexeddbshim: true,
pathjs: true
},
devtool: "#inline-source-map",
module: {
loaders: [
{
test: /.js$/,
include: __dirname + "/src",
loader: 'babel-loader'
}
]
},
/*
plugins: [
new webpack.SourceMapDevToolPlugin(
'/www/scripts/test/test.js.map', null,
"[absolute-resource-path]", "[absolute-resource-path]"
)
],
*/
resolve: {
root: [
__dirname + "/src"
]
}
},
port: 9876,
colors: true,
autoWatch: false,
singleRun: true,
files: [
"src/Core/Test/TestRunner.js"
],
reporters: ["progress"/*, "coverage"*/],
exclude: ["src/MSUD/Index.js"],
frameworks: ['mocha', 'chai'],
browsers: ['PhantomJS']
/*
coverageReporter: {
dir: 'coverage/',
reporters: [
{
type: 'html',
subdir: 'html'
},
{
type: 'lcovonly',
subdir: 'lcov'
},
{
type: 'cobertura',
subdir: 'cobertura'
},
{type: 'text'}
]
}
*/
});
};