DEV: Run tests with new chrome headless (#21684)
New headless shares the same implementation as the chrome browser instead of being a separate implementation of its own. See https://developer.chrome.com/articles/new-headless/ for more details Co-authored-by: Rafael dos Santos Silva <xfalcox@gmail.com>
This commit is contained in:
parent
4676524094
commit
dab37c1a5a
|
@ -96,7 +96,7 @@ module.exports = {
|
|||
Chrome: [
|
||||
// --no-sandbox is needed when running Chrome inside a container
|
||||
process.env.CI ? "--no-sandbox" : null,
|
||||
"--headless",
|
||||
"--headless=new",
|
||||
"--disable-dev-shm-usage",
|
||||
"--disable-software-rasterizer",
|
||||
"--mute-audio",
|
||||
|
|
|
@ -297,7 +297,7 @@ RSpec.configure do |config|
|
|||
end
|
||||
|
||||
Capybara.register_driver :selenium_chrome_headless do |app|
|
||||
chrome_browser_options.add_argument("--headless")
|
||||
chrome_browser_options.add_argument("--headless=new")
|
||||
|
||||
Capybara::Selenium::Driver.new(app, browser: :chrome, options: chrome_browser_options)
|
||||
end
|
||||
|
@ -319,7 +319,7 @@ RSpec.configure do |config|
|
|||
end
|
||||
|
||||
Capybara.register_driver :selenium_mobile_chrome_headless do |app|
|
||||
mobile_chrome_browser_options.add_argument("--headless")
|
||||
mobile_chrome_browser_options.add_argument("--headless=new")
|
||||
Capybara::Selenium::Driver.new(app, browser: :chrome, options: mobile_chrome_browser_options)
|
||||
end
|
||||
|
||||
|
|
|
@ -37,7 +37,7 @@ async function runAllTests() {
|
|||
const options = {
|
||||
chromeFlags: [
|
||||
"--disable-gpu",
|
||||
"--headless",
|
||||
"--headless=new",
|
||||
"--no-sandbox",
|
||||
"--disable-dev-shm-usage",
|
||||
"--mute-audio",
|
||||
|
|
Loading…
Reference in New Issue