From 6b02c7874827eb6662a1a50544df1171a0679180 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jesper=20S=C3=B8rensen?= Date: Mon, 18 Dec 2023 11:57:36 +0100 Subject: [PATCH] Temporarily Work around issue with selenium --- spec/support/capybara.rb | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/spec/support/capybara.rb b/spec/support/capybara.rb index 4c5550c40..56e33b68b 100644 --- a/spec/support/capybara.rb +++ b/spec/support/capybara.rb @@ -22,6 +22,12 @@ driven_by(:selenium, using: ENV.fetch("CAPYBARA_DRIVER", "headless_chrome").to_sym, screen_size: [1920, 1080]) do |capabilities| capabilities.add_argument("--no-sandbox") if ENV["CAPYBARA_NO_SANDBOX"].present? + + # Until this is released: + # https://github.com/SeleniumHQ/selenium/pull/13271 + # Use the recommended workaround: + # https://github.com/SeleniumHQ/selenium/pull/13271#issuecomment-1854042830 + capabilities.add_argument("--headless=new") if capabilities.args.delete("--headless") end end end