app_file = File.join( File.dirname(__FILE__), *%w[.. lib app.rb] ) require app_file # Force the application name because polyglot breaks the auto-detection logic. Sinatra::Application.app_file = app_file require 'spec/expectations' require 'spec/interop/test' require 'rack/test' require 'sinatra/test' require 'capybara' # Webrat.configure do |config| # config.mode = :rack # end class MyWorld include Rack::Test::Methods # include Webrat::Methods # include Webrat::Matchers # Webrat::Methods.delegate_to_session :response_code, :response_body def app Sinatra::Application end end World{MyWorld.new}