From 5256a91fb2944d90cdb925963a8c523ceaba5d40 Mon Sep 17 00:00:00 2001 From: Paul Gschwendtner Date: Wed, 12 Dec 2018 23:07:21 +0100 Subject: [PATCH] build: update to latest karma-sauce-launcher version (#27634) PR Close #27634 --- karma-js.conf.js | 15 +++++---------- package.json | 2 +- scripts/ci/env.sh | 2 +- yarn.lock | 25 ++++++++++++++++++++++--- 4 files changed, 29 insertions(+), 15 deletions(-) diff --git a/karma-js.conf.js b/karma-js.conf.js index 1986a04eb1..dc9e8bd73d 100644 --- a/karma-js.conf.js +++ b/karma-js.conf.js @@ -122,12 +122,9 @@ module.exports = function(config) { startConnect: false, recordVideo: false, recordScreenshots: false, - options: { - 'selenium-version': '2.53.0', - 'command-timeout': 600, - 'idle-timeout': 600, - 'max-duration': 5400, - } + idleTimeout: 600, + commandTimeout: 600, + maxDuration: 5400, }, browserStack: { @@ -154,10 +151,8 @@ module.exports = function(config) { config.sauceLabs.build = buildId; config.sauceLabs.tunnelIdentifier = process.env.TRAVIS_JOB_NUMBER; - // TODO(mlaval): remove once SauceLabs supports websockets. - // This speeds up the capturing a bit, as browsers don't even try to use websocket. - console.log('>>>> setting socket.io transport to polling <<<<'); - config.transports = ['polling']; + // Try "websocket" for a faster transmission first. Fallback to "polling" if necessary. + config.transports = ['websocket', 'polling']; } if (process.env.CI_MODE.startsWith('browserstack')) { diff --git a/package.json b/package.json index 5bfabbdec4..cae0a9e39f 100644 --- a/package.json +++ b/package.json @@ -123,7 +123,7 @@ "karma-browserstack-launcher": "^1.3.0", "karma-chrome-launcher": "^2.2.0", "karma-jasmine": "^1.1.2", - "karma-sauce-launcher": "^1.2.0", + "karma-sauce-launcher": "^2.0.2", "karma-sourcemap-loader": "^0.3.7", "madge": "0.5.0", "mutation-observer": "^1.0.3", diff --git a/scripts/ci/env.sh b/scripts/ci/env.sh index 662cc97634..78adcf8c5a 100755 --- a/scripts/ci/env.sh +++ b/scripts/ci/env.sh @@ -38,7 +38,7 @@ setEnvVar NODE_VERSION 10.9.0 setEnvVar YARN_VERSION 1.12.1 setEnvVar CHROMIUM_VERSION 561733 # Chrome 68 linux stable, see https://www.chromium.org/developers/calendar setEnvVar CHROMEDRIVER_VERSION_ARG "--versions.chrome 2.41" -setEnvVar SAUCE_CONNECT_VERSION 4.4.9 +setEnvVar SAUCE_CONNECT_VERSION 4.5.2 setEnvVar ANGULAR_CLI_VERSION 1.6.3 setEnvVar CI_AIO_MIN_PWA_SCORE 95 setEnvVar CI_BRANCH $TRAVIS_BRANCH diff --git a/yarn.lock b/yarn.lock index e7031fb5d1..545eab926c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4660,7 +4660,7 @@ karma-requirejs@1.1.0: resolved "https://registry.yarnpkg.com/karma-requirejs/-/karma-requirejs-1.1.0.tgz#fddae2cb87d7ebc16fb0222893564d7fee578798" integrity sha1-/driy4fX68FvsCIok1ZNf+5Xh5g= -karma-sauce-launcher@1.2.0, karma-sauce-launcher@^1.2.0: +karma-sauce-launcher@1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/karma-sauce-launcher/-/karma-sauce-launcher-1.2.0.tgz#6f2558ddef3cf56879fa27540c8ae9f8bfd16bca" integrity sha512-lEhtGRGS+3Yw6JSx/vJY9iQyHNtTjcojrSwNzqNUOaDceKDu9dPZqA/kr69bUO9G2T6GKbu8AZgXqy94qo31Jg== @@ -4670,6 +4670,15 @@ karma-sauce-launcher@1.2.0, karma-sauce-launcher@^1.2.0: saucelabs "^1.4.0" wd "^1.4.0" +karma-sauce-launcher@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/karma-sauce-launcher/-/karma-sauce-launcher-2.0.2.tgz#dbf98e70d86bf287b03a537cf637eb7aefa975c3" + integrity sha512-jLUFaJhHMcKpxFWUesyWYihzM5FvQiJsDwGcCtKeOy2lsWhkVw0V0Byqb1d+wU6myU1mribBtsIcub23HS4kWA== + dependencies: + sauce-connect-launcher "^1.2.4" + saucelabs "^1.5.0" + selenium-webdriver "^4.0.0-alpha.1" + karma-sourcemap-loader@0.3.7, karma-sourcemap-loader@^0.3.7: version "0.3.7" resolved "https://registry.yarnpkg.com/karma-sourcemap-loader/-/karma-sourcemap-loader-0.3.7.tgz#91322c77f8f13d46fed062b042e1009d4c4505d8" @@ -7166,7 +7175,7 @@ safe-regex@^1.1.0: resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== -sauce-connect-launcher@^1.2.2: +sauce-connect-launcher@^1.2.2, sauce-connect-launcher@^1.2.4: version "1.2.4" resolved "https://registry.yarnpkg.com/sauce-connect-launcher/-/sauce-connect-launcher-1.2.4.tgz#8d38f85242a9fbede1b2303b559f7e20c5609a1c" integrity sha512-X2vfwulR6brUGiicXKxPm1GJ7dBEeP1II450Uv4bHGrcGOapZNgzJvn9aioea5IC5BPp/7qjKdE3xbbTBIVXMA== @@ -7177,7 +7186,7 @@ sauce-connect-launcher@^1.2.2: lodash "^4.16.6" rimraf "^2.5.4" -saucelabs@^1.4.0: +saucelabs@^1.4.0, saucelabs@^1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/saucelabs/-/saucelabs-1.5.0.tgz#9405a73c360d449b232839919a86c396d379fd9d" integrity sha512-jlX3FGdWvYf4Q3LFfFWS1QvPg3IGCGWxIc8QBFdPTbpTJnt/v17FHXYVAn7C8sHf1yUXo2c7yIM0isDryfYtHQ== @@ -7232,6 +7241,16 @@ selenium-webdriver@^2.53.2: ws "^1.0.1" xml2js "0.4.4" +selenium-webdriver@^4.0.0-alpha.1: + version "4.0.0-alpha.1" + resolved "https://registry.yarnpkg.com/selenium-webdriver/-/selenium-webdriver-4.0.0-alpha.1.tgz#cc93415e21d2dc1dfd85dfc5f6b55f3ac53933b1" + integrity sha512-z88rdjHAv3jmTZ7KSGUkTvo4rGzcDGMq0oXWHNIDK96Gs31JKVdu9+FMtT4KBrVoibg8dUicJDok6GnqqttO5Q== + dependencies: + jszip "^3.1.3" + rimraf "^2.5.4" + tmp "0.0.30" + xml2js "^0.4.17" + "semver@2 || 3 || 4", semver@^4.1.0: version "4.3.6" resolved "https://registry.yarnpkg.com/semver/-/semver-4.3.6.tgz#300bc6e0e86374f7ba61068b5b1ecd57fc6532da"