This repository has been archived by the owner on Feb 19, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 11
/
karma.conf.saucelabs.js
67 lines (63 loc) · 1.63 KB
/
karma.conf.saucelabs.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
/**
* Karma Configuration: Base.
*/
var path = require("path");
var baseCfg = require("./karma.conf");
// Sauce labs environments.
var SAUCE_ENVS = {
"chrome-mac": {
base: "SauceLabs",
browserName: "chrome",
platform: "OS X 10.9"
},
"safari-mac": {
base: "SauceLabs",
browserName: "safari",
platform: "OS X 10.9"
},
// TODO: Appears to fail conversion tests.
// "ie9-win7": {
// base: "SauceLabs",
// browserName: "internet explorer",
// platform: "Windows 7",
// version: "9"
// },
"ie10-win7": {
base: "SauceLabs",
browserName: "internet explorer",
platform: "Windows 7",
version: "10"
},
"ie11-win7": {
base: "SauceLabs",
browserName: "internet explorer",
platform: "Windows 7",
version: "11"
}
};
// Optionally filter browsers from environment or "all browsers"
var BROWSERS = (process.env.BROWSERS || "")
.split(",")
.filter(function (x) { return x; });
if (!BROWSERS.length) {
BROWSERS = Object.keys(SAUCE_ENVS);
}
// SauceLabs tag.
var SAUCE_BRANCH = process.env.TRAVIS_BRANCH || "local";
var SAUCE_TAG = process.env.SAUCE_USERNAME + "@" + SAUCE_BRANCH;
module.exports = function(config) {
baseCfg(config);
config.set({
reporters: ["spec", "saucelabs"],
sauceLabs: {
testName: "full-stack-testing - Frontend Unit Tests",
tags: [SAUCE_TAG],
public: "public"
},
// Timeouts: Allow "n" minutes before saying "good enough". See also:
// https://github.com/angular/angular.js/blob/master/karma-shared.conf.js
captureTimeout: 0, // Pass through to SL.
customLaunchers: SAUCE_ENVS,
browsers: BROWSERS
});
};