Require rack/test in rack session
This commit is contained in:
parent
0a3b979772
commit
92ec1c3d92
|
@ -1,6 +1,7 @@
|
||||||
|
require "rack/test"
|
||||||
|
|
||||||
module Webrat
|
module Webrat
|
||||||
class RackSession < Session
|
class RackSession < Session
|
||||||
|
|
||||||
def initialize(rack_test_session) #:nodoc:
|
def initialize(rack_test_session) #:nodoc:
|
||||||
super()
|
super()
|
||||||
@rack_test_session = rack_test_session
|
@rack_test_session = rack_test_session
|
||||||
|
@ -27,6 +28,5 @@ module Webrat
|
||||||
env = headers.merge(:params => data, :method => http_method.to_s.upcase)
|
env = headers.merge(:params => data, :method => http_method.to_s.upcase)
|
||||||
@rack_test_session.request(url, env)
|
@rack_test_session.request(url, env)
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue