Make all spec work, switch to thoughtbot way of integration testing

This commit is contained in:
2013-04-10 17:06:47 +02:00
parent 7b71e677c9
commit 20fa6ac805
12 changed files with 175 additions and 220 deletions
+8 -5
View File
@@ -6,16 +6,19 @@
require 'cucumber/rails'
require 'capybara/poltergeist'
#Capybara.javascript_driver = :poltergeist
poltergeist = false
# Capybara defaults to XPath selectors rather than Webrat's default of CSS3. In
# order to ease the transition to Capybara we set the default here. If you'd
# prefer to use XPath just remove this line and adjust any selectors in your
# steps to use the XPath syntax.
Capybara.default_selector = :css
Capybara.register_driver :selenium do |app|
#Capybara::Selenium::Driver.new(app, :browser => :chrome)
Capybara::Selenium::Driver.new(app, :browser => :firefox)
if poltergeist
Capybara.javascript_driver = :poltergeist
else
Capybara.register_driver :selenium do |app|
#Capybara::Selenium::Driver.new(app, :browser => :chrome)
Capybara::Selenium::Driver.new(app, :browser => :firefox)
end
end
# By default, any exception happening in your Rails application will bubble up