diff --git a/lib/webrat/core/session.rb b/lib/webrat/core/session.rb index 31c508e..eda7377 100644 --- a/lib/webrat/core/session.rb +++ b/lib/webrat/core/session.rb @@ -20,8 +20,6 @@ module Webrat MerbSession when :selenium SeleniumSession - when :rack - RackSession when :sinatra SinatraSession when :mechanize diff --git a/lib/webrat/rack.rb b/lib/webrat/rack.rb deleted file mode 100644 index b537afb..0000000 --- a/lib/webrat/rack.rb +++ /dev/null @@ -1,24 +0,0 @@ -require 'webrat' - -class CGIMethods #:nodoc: - def self.parse_query_parameters(params) - hash = {} - params.split('&').each do |p| - pair = p.split('=') - hash[pair[0]] = pair[1] - end - hash - end -end - -module Webrat - class RackSession < Session #:nodoc: - def response_body - @response.body - end - - def response_code - @response.status - end - end -end diff --git a/lib/webrat/sinatra.rb b/lib/webrat/sinatra.rb index efaa491..796cd37 100644 --- a/lib/webrat/sinatra.rb +++ b/lib/webrat/sinatra.rb @@ -2,7 +2,7 @@ require "webrat/rack" require "sinatra/test" module Webrat - class SinatraSession < RackSession + class SinatraSession < Session include Sinatra::Test attr_reader :request, :response