Class: Capybara::Playwright::BrowserOptions

Inherits:
Object
  • Object
show all
Defined in:
lib/capybara/playwright/browser_options.rb

Constant Summary collapse

LAUNCH_PARAMS =
{
  args: nil,
  channel: nil,
  chromiumSandbox: nil,
  devtools: nil,
  downloadsPath: nil,
  env: nil,
  executablePath: nil,
  firefoxUserPrefs: nil,
  handleSIGHUP: nil,
  handleSIGINT: nil,
  handleSIGTERM: nil,
  headless: nil,
  ignoreDefaultArgs: nil,
  proxy: nil,
  slowMo: nil,
  # timeout: nil,
  tracesDir: nil,
}.keys

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ BrowserOptions

Returns a new instance of BrowserOptions.



4
5
6
# File 'lib/capybara/playwright/browser_options.rb', line 4

def initialize(options)
  @options = options
end

Instance Method Details

#valueObject



28
29
30
# File 'lib/capybara/playwright/browser_options.rb', line 28

def value
  @options.select { |k, _| LAUNCH_PARAMS.include?(k) }
end