Skip to content

Commit

Permalink
Register capybara driver
Browse files Browse the repository at this point in the history
  • Loading branch information
JoonasAapro committed Dec 29, 2023
1 parent 90d7211 commit a12fef1
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 70 deletions.
70 changes: 0 additions & 70 deletions .github/actions/module-rspec/action.yml

This file was deleted.

17 changes: 17 additions & 0 deletions lib/decidim/iframe/engine.rb
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,23 @@ class Engine < ::Rails::Engine
end
end

Capybara.register_driver :headless_chrome do |app|
options = ::Selenium::WebDriver::Chrome::Options.new
options.args << "--headless=new"
options.args << "--no-sandbox"
options.args << if ENV["BIG_SCREEN_SIZE"].present?
"--window-size=1920,3000"
else
"--window-size=1920,1080"
end
options.args << "--ignore-certificate-errors" if ENV["TEST_SSL"]
Capybara::Selenium::Driver.new(
app,
browser: :chrome,
capabilities: [options]
)
end

def load_seed
nil
end
Expand Down

0 comments on commit a12fef1

Please sign in to comment.