1
0
Fork 0
mirror of https://github.com/teamcapybara/capybara.git synced 2022-11-09 12:08:07 -05:00
teamcapybara--capybara/lib/capybara/rails.rb

17 lines
322 B
Ruby
Raw Normal View History

2009-11-16 16:02:16 -05:00
require 'capybara'
require 'capybara/dsl'
Capybara.app = Rack::Builder.new do
map "/" do
2010-02-24 03:25:47 -05:00
if Rails.version.to_f >= 3.0
run Rails.application
else # Rails 2
use Rails::Rack::Static
run ActionController::Dispatcher.new
end
2009-11-16 16:02:16 -05:00
end
2010-01-01 11:48:39 -05:00
end.to_app
2009-11-16 16:02:16 -05:00
Capybara.asset_root = Rails.root.join('public')
2010-02-21 19:59:17 -05:00