diff --git a/package.json b/package.json index 226e8ac1593aa..028a0e32b5890 100644 --- a/package.json +++ b/package.json @@ -794,7 +794,7 @@ "sass-embedded": "^1.70.0", "sass-loader": "^10.5.1", "sass-resources-loader": "^2.0.1", - "selenium-webdriver": "^4.16.0", + "selenium-webdriver": "^4.17.0", "simple-git": "^3.16.0", "sinon": "^7.4.2", "sort-package-json": "^1.53.1", diff --git a/test/functional/services/remote/webdriver.ts b/test/functional/services/remote/webdriver.ts index ee6f7c36fe349..7ca8ec5006ab5 100644 --- a/test/functional/services/remote/webdriver.ts +++ b/test/functional/services/remote/webdriver.ts @@ -99,7 +99,7 @@ function initChromiumOptions(browserType: Browsers, acceptInsecureCerts: boolean if (headlessBrowser === '1') { // Use --disable-gpu to avoid an error from a missing Mesa library, as per // See: https://chromium.googlesource.com/chromium/src/+/lkgr/headless/README.md - options.headless(); + options.addArguments('headless=old'); options.addArguments('disable-gpu'); } @@ -109,7 +109,7 @@ function initChromiumOptions(browserType: Browsers, acceptInsecureCerts: boolean if (remoteDebug === '1') { // Visit chrome://inspect in chrome to remotely view/debug - options.headless(); + options.addArguments('headless=old'); options.addArguments('disable-gpu', 'remote-debugging-port=9222'); } @@ -224,8 +224,8 @@ async function attemptToCreateCommand( firefoxOptions.setAcceptInsecureCerts(config.acceptInsecureCerts); if (headlessBrowser === '1') { - // See: https://developer.mozilla.org/en-US/docs/Mozilla/Firefox/Headless_mode - firefoxOptions.headless(); + // See: https://developer.mozilla.org/en-US/docs/Web/WebDriver/Capabilities/firefoxOptions + firefoxOptions.addArguments('-headless'); } // Windows issue with stout socket https://github.com/elastic/kibana/issues/52053 diff --git a/yarn.lock b/yarn.lock index a4fec04fa65d5..da7d2251a5d8d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -25051,10 +25051,10 @@ select-hose@^2.0.0: resolved "https://registry.yarnpkg.com/select-hose/-/select-hose-2.0.0.tgz#625d8658f865af43ec962bfc376a37359a4994ca" integrity sha1-Yl2GWPhlr0Psliv8N2o3NZpJlMo= -selenium-webdriver@^4.16.0: - version "4.16.0" - resolved "https://registry.yarnpkg.com/selenium-webdriver/-/selenium-webdriver-4.16.0.tgz#2f1a2426d876aa389d1c937b00f034c2c7808360" - integrity sha512-IbqpRpfGE7JDGgXHJeWuCqT/tUqnLvZ14csSwt+S8o4nJo3RtQoE9VR4jB47tP/A8ArkYsh/THuMY6kyRP6kuA== +selenium-webdriver@^4.17.0: + version "4.17.0" + resolved "https://registry.yarnpkg.com/selenium-webdriver/-/selenium-webdriver-4.17.0.tgz#f6c93a9df3e0543df7dc2329d81968af42845a7f" + integrity sha512-e2E+2XBlGepzwgFbyQfSwo9Cbj6G5fFfs9MzAS00nC99EewmcS2rwn2MwtgfP7I5p1e7DYv4HQJXtWedsu6DvA== dependencies: jszip "^3.10.1" tmp "^0.2.1"