parent
5eeceff9e8
commit
3e7886ecab
|
@ -20,8 +20,6 @@ module Webrat
|
|||
MerbSession
|
||||
when :selenium
|
||||
SeleniumSession
|
||||
when :rack
|
||||
RackSession
|
||||
when :sinatra
|
||||
SinatraSession
|
||||
when :mechanize
|
||||
|
|
|
@ -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
|
|
@ -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
|
||||
|
|
Loading…
Reference in New Issue