lib/action_controller/test_process.rb in actionpack-1.6.0 vs lib/action_controller/test_process.rb in actionpack-1.7.0

- old
+ new

@@ -249,15 +249,16 @@ module Test module Unit class TestCase #:nodoc: private # execute the request and set/volley the response - def process(action, parameters = nil, session = nil) + def process(action, parameters = nil, session = nil, flash = nil) @request.env['REQUEST_METHOD'] ||= "GET" @request.action = action.to_s @request.path_parameters = { :controller => @controller.class.controller_path } @request.parameters.update(parameters) unless parameters.nil? @request.session = ActionController::TestSession.new(session) unless session.nil? + @request.session["flash"] = ActionController::Flash::FlashHash.new.update(flash) if flash @controller.process(@request, @response) end # execute the request simulating a specific http method and set/volley the response %w( get post put delete head ).each do |method|