Sha256: f4d5d3c7b360188dcd52108263eabfb44a7cc8f3a677adb233517d8949ba5a9b
Contents?: true
Size: 907 Bytes
Versions: 1
Compression:
Stored size: 907 Bytes
Contents
# :testingbot driver Capybara.register_driver :testingbot do |app| caps = CapybaraHelpers.required_cloud_caps.merge( maxduration: Howitzer.cloud_max_duration, idletimeout: Howitzer.cloud_testingbot_idle_timeout, screenshot: Howitzer.cloud_testingbot_screenshots ) if Howitzer.user_agent.present? if CapybaraHelpers.chrome_browser? caps['chromeOptions'] = { 'args' => ["--user-agent=#{Howitzer.user_agent}"] } elsif CapybaraHelpers.ff_browser? profile = Selenium::WebDriver::Firefox::Profile.new profile['general.useragent.override'] = Howitzer.user_agent caps[:firefox_profile] = profile end end url = "https://#{Howitzer.cloud_auth_login}:#{Howitzer.cloud_auth_pass}@hub.testingbot.com/wd/hub" CapybaraHelpers.cloud_driver(app, caps, url) end Capybara::Screenshot.class_eval do register_driver :testingbot, ®istered_drivers[:selenium] end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
howitzer-2.3.0 | generators/config/templates/drivers/testingbot.rb |