Class: ActionDispatch::SystemTesting::Driver

Inherits:
Object
  • Object
show all
Defined in:
lib/action_dispatch/system_testing/driver.rb

Overview

:nodoc:

Instance Method Summary collapse

Constructor Details

#initialize(name, **options, &capabilities) ⇒ Driver

Returns a new instance of Driver.



6
7
8
9
10
11
12
13
14
15
16
17
# File 'lib/action_dispatch/system_testing/driver.rb', line 6

def initialize(name, **options, &capabilities)
  @name = name
  @browser = Browser.new(options[:using])
  @screen_size = options[:screen_size]
  @options = options[:options] || {}
  @capabilities = capabilities

  if name == :selenium
    require "selenium/webdriver"
    @browser.preload
  end
end

Instance Method Details

#useObject



19
20
21
22
23
# File 'lib/action_dispatch/system_testing/driver.rb', line 19

def use
  register if registerable?

  setup
end