-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathbrowser-providers.conf.js
172 lines (168 loc) · 5.44 KB
/
browser-providers.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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
// Unique place to configure the browsers which are used in the different CI jobs in Sauce Labs (SL).
// If the target is set to null, then the browser is not run anywhere during CI.
var CIconfiguration = {
'Chrome': { unitTest: {target: 'SL', required: true }, e2e: {target: null, required: false}},
'Chrome-1': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'Chrome-2': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'Firefox': { unitTest: {target: 'SL', required: true }, e2e: {target: null, required: false}},
'Firefox-1': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'Firefox-2': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'IE': { unitTest: {target: 'SL', required: true }, e2e: {target: null, required: false}},
'IE-1': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'IE-2': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'Edge': { unitTest: {target: 'SL', required: true }, e2e: {target: null, required: false}},
'Edge-1': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'Edge-2': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'Android': { unitTest: {target: 'SL', required: true }, e2e: {target: null, required: false}},
'Android-1': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'Android-2': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'Safari': { unitTest: {target: 'SL', required: true }, e2e: {target: null, required: false}},
'Safari-1': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'Safari-2': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'iOS': { unitTest: {target: 'SL', required: true }, e2e: {target: null, required: false}},
'iOS-1': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}},
'iOS-2': { unitTest: {target: 'SL', required: false}, e2e: {target: null, required: false}}
};
var customLaunchers = {
'SL_CHROME': {
base: 'SauceLabs',
browserName: 'chrome',
version: '59'
},
'SL_CHROME-1': {
base: 'SauceLabs',
browserName: 'chrome',
version: '58'
},
'SL_CHROME-2': {
base: 'SauceLabs',
browserName: 'chrome',
version: '57'
},
'SL_FIREFOX': {
base: 'SauceLabs',
browserName: 'firefox',
version: '54'
},
'SL_FIREFOX-1': {
base: 'SauceLabs',
browserName: 'firefox',
version: '53'
},
'SL_FIREFOX-2': {
base: 'SauceLabs',
browserName: 'firefox',
version: '52'
},
'SL_SAFARI': {
base: 'SauceLabs',
browserName: 'safari',
platform: 'OS X 10.12',
version: '10.0'
},
'SL_SAFARI-1': {
base: 'SauceLabs',
browserName: 'safari',
platform: 'OS X 10.11',
version: '9'
},
'SL_SAFARI-2': {
base: 'SauceLabs',
browserName: 'safari',
platform: 'OS X 10.10',
version: '8'
},
'SL_IOS': {
base: 'SauceLabs',
browserName: 'iphone',
platform: 'OS X 10.10',
version: '10.0'
},
'SL_IOS-1': {
base: 'SauceLabs',
browserName: 'iphone',
platform: 'OS X 10.10',
version: '9.1'
},
'SL_IOS-2': {
base: 'SauceLabs',
browserName: 'iphone',
platform: 'OS X 10.10',
version: '8.4'
},
'SL_IE': {
base: 'SauceLabs',
browserName: 'internet explorer',
platform: 'Windows 10',
version: '11'
},
'SL_IE-1': {
base: 'SauceLabs',
browserName: 'internet explorer',
platform: 'Windows 8',
version: '10'
},
'SL_IE-2': {
base: 'SauceLabs',
browserName: 'internet explorer',
platform: 'Windows 7',
version: '9'
},
'SL_EDGE': {
base: 'SauceLabs',
browserName: 'MicrosoftEdge',
platform: 'Windows 10',
version: 'latest'
},
'SL_EDGE-1': {
base: 'SauceLabs',
browserName: 'MicrosoftEdge',
platform: 'Windows 10',
version: '14'
},
'SL_EDGE-2': {
base: 'SauceLabs',
browserName: 'MicrosoftEdge',
platform: 'Windows 10',
version: '13'
},
'SL_ANDROID': {
base: 'SauceLabs',
browserName: 'android',
platform: 'Linux',
version: 'latest'
},
'SL_ANDROID-1': {
base: 'SauceLabs',
browserName: 'android',
platform: 'Linux',
version: 'latest-1'
},
'SL_ANDROID-2': {
base: 'SauceLabs',
browserName: 'android',
platform: 'Linux',
version: 'latest-2'
}
};
var saucelabsAliases = {
'ALL': Object.keys(customLaunchers).filter(function(item) {return customLaunchers[item].base == 'SauceLabs';}),
'CI_TEST_REQUIRED': buildConfiguration('unitTest', 'SL', true),
'CI_TEST_OPTIONAL': buildConfiguration('unitTest', 'SL', false),
'CI_E2E_REQUIRED': buildConfiguration('e2e', 'SL', true),
'CI_E2E_OPTIONAL': buildConfiguration('e2e', 'SL', false)
};
module.exports = {
customLaunchers: customLaunchers,
saucelabsAliases: saucelabsAliases,
};
function buildConfiguration(type, target, required) {
return Object.keys(CIconfiguration)
.filter((item) => {
var conf = CIconfiguration[item][type];
return conf.required === required && conf.target === target;
})
.map((item) => {
return target + '_' + item.toUpperCase();
});
}