Test capybara fix

This commit is contained in:
Steve Klabnik 2012-12-08 15:22:54 -08:00
parent 0bb5834efd
commit 0449514d01
1 changed files with 13 additions and 5 deletions

View File

@ -12,11 +12,19 @@ RSpec.configure do |config|
}
end
module Draper
module RSpec
class Railtie < Rails::Railtie
config.after_initialize do |app|
if defined?(Capybara)
require 'capybara/rspec/matchers'
if defined?(Capybara)
require 'capybara/rspec/matchers'
RSpec.configure do |config|
config.include Capybara::RSpecMatchers, :type => :decorator
RSpec.configure do |config|
config.include Capybara::RSpecMatchers, :type => :decorator
end
end
end
end
end
end