Skip to content

Commit b9ebb79

Browse files
committed
build: do not e2e tests on saucelabs
* No longer runs e2e tests inside of Saucelabs because Chrome is also installed on Travis CI and we should keep Saucelabs available for other browsers that don't run inside of Dockers or Travis.
1 parent b2247f8 commit b9ebb79

File tree

3 files changed

+13
-29
lines changed

3 files changed

+13
-29
lines changed

scripts/ci/travis-testing.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,9 @@ wait_for_tunnel
3434
if is_lint; then
3535
$(npm bin)/gulp ci:lint
3636
elif is_e2e; then
37-
$(npm bin)/gulp ci:e2e
37+
# Run e2e tests inside of Xvfb because we need to test the HTML Fullscreen API's that cannot
38+
# be tested within Chrome headless.
39+
xvfb-run -a --server-args='-screen 0, 1024x768x16' $(npm bin)/gulp ci:e2e
3840
elif is_aot; then
3941
$(npm bin)/gulp ci:aot
4042
elif is_payload; then

scripts/saucelabs/sauce_config.js

Lines changed: 0 additions & 1 deletion
This file was deleted.

test/protractor.conf.js

Lines changed: 10 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ require('ts-node').register({
55
project: path.join(__dirname, '../e2e/')
66
});
77

8-
98
const E2E_BASE_URL = process.env['E2E_BASE_URL'] || 'http://localhost:4200';
10-
const config = {
9+
10+
exports.config = {
1111
useAllAngular2AppRoots: true,
1212
specs: [ path.join(__dirname, '../e2e/**/*.spec.ts') ],
1313
baseUrl: E2E_BASE_URL,
@@ -27,34 +27,17 @@ const config = {
2727
// Exclude mat-menu elements because those are empty if not active.
2828
{ id: 'aria-required-children', selector: '*:not(mat-menu)' },
2929

30-
// Disable color constrast checks since the final colors will vary based on the theme.
30+
// Disable color contrast checks since the final colors will vary based on the theme.
3131
{ id: 'color-contrast', enabled: false },
3232
]
3333
}
34-
]
35-
};
36-
37-
if (process.env['TRAVIS']) {
38-
const key = require('../scripts/saucelabs/sauce_config');
34+
],
3935

40-
config.sauceUser = process.env['SAUCE_USERNAME'];
41-
config.sauceKey = key;
42-
config.capabilities = {
43-
'browserName': 'chrome',
44-
'version': 'latest',
45-
'tunnel-identifier': process.env['TRAVIS_JOB_ID'],
46-
'build': process.env['TRAVIS_JOB_ID'],
47-
'name': 'Material E2E Tests',
36+
capabilities: {
37+
browserName: 'chrome',
4838

4939
// Enables concurrent testing in the Webdriver. Currently runs five e2e files in parallel.
50-
'maxInstances': 5,
51-
'shardTestFiles': true,
52-
53-
// By default Saucelabs tries to record the whole e2e run. This can slow down the builds.
54-
'recordVideo': false,
55-
'recordScreenshots': false
56-
};
57-
}
58-
59-
60-
exports.config = config;
40+
shardTestFiles: true,
41+
maxInstances: 5,
42+
}
43+
};

0 commit comments

Comments
 (0)