-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathkarma.conf.js
50 lines (45 loc) · 1.19 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
var bridgeDbDefaultConfig = require("./lib/config.js");
//require('./test/mockserver.js');
module.exports = function(config) {
var options = {
basePath: "",
frameworks: ["mocha", "chai", "browserify"],
browsers: ["Chrome", "Firefox"],
files: ["test/unit/ui-components/**/*.test.js"],
preprocessors: {
"test/unit/ui-components/**/*.js": "browserify"
},
browserify: {
debug: true,
transform: ["brfs"]
},
colors: true,
reporters: ["coverage", "mocha"],
browserDisconnectTimeout: 60000,
browserNoActivityTimeout: 60000,
client: {
mocha: {
timeout: 59000
}
}
};
process.env.MOCKSERVER_PORT = 4522;
var proxies = {};
proxies[bridgeDbDefaultConfig.baseIri] = {
target: "http://localhost:" + process.env.MOCKSERVER_PORT + "/",
changeOrigin: true
};
proxies[bridgeDbDefaultConfig.datasetsMetadataIri] = {
target:
"http://localhost:" + process.env.MOCKSERVER_PORT + "/datasources.txt",
changeOrigin: true
};
options.proxies = proxies;
if (process.env.CIRCLECI) {
options.singleRun = true;
}
if (process.env.GROWL) {
options.reporters.push("growl");
}
config.set(options);
};