Sha256: fed969aedba96aedbf047ca640a8dc0a4414607d56121e1f4de570a5cdce4441
Contents?: true
Size: 1.26 KB
Versions: 1
Compression:
Stored size: 1.26 KB
Contents
require 'watir-webdriver' module WatirWebdriverRails # Copied from capybara-firebug class Selenium::WebDriver::Firefox::Profile def self.firebug_version @firebug_version ||= '1.7.3' end def self.firebug_version=(version) @firebug_version = version end def enable_firebug(version = nil) version ||= Selenium::WebDriver::Firefox::Profile.firebug_version add_extension(File.expand_path("../firebug/firebug-1.7.3.xpi", __FILE__)) add_extension(File.expand_path("../firebug/firebug-1.8.1.xpi", __FILE__)) # Prevent "Welcome!" tab self["extensions.firebug.currentVersion"] = "999" # Enable for all sites. self["extensions.firebug.allPagesActivation"] = "on" # Enable all features. ['console', 'net', 'script'].each do |feature| self["extensions.firebug.#{feature}.enableSites"] = true end # Closed by default. self["extensions.firebug.previousPlacement"] = 3 end end class << self def driver profile = Selenium::WebDriver::Firefox::Profile.new profile.enable_firebug driver = Selenium::WebDriver.for(:firefox, { :profile => profile }) return driver end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
watir-webdriver-rails-0.0.6 | lib/watir-webdriver-rails/driver.rb |