Sha256: 004e8c6a79dbfac709df464fba0a18339fe77408e69352cf8cc5ac64de0ab5b1
Contents?: true
Size: 946 Bytes
Versions: 1
Compression:
Stored size: 946 Bytes
Contents
require 'selenium/webdriver' class Selenium::WebDriver::Firefox::Profile def enable_firebug add_extension(File.expand_path("../firebug-1.6.2.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 Capybara.register_driver :selenium_with_firebug do |app| profile = Selenium::WebDriver::Firefox::Profile.new profile.enable_firebug Capybara::Driver::Selenium.new(app, :browser => :firefox, :profile => profile) end Before '@firebug' do Capybara.current_driver = :selenium_with_firebug end Then /^stop and let me debug$/ do require 'ruby-debug' debugger end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
capybara-firebug-0.0.2 | lib/capybara/firebug.rb |