diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-02-12 21:54:34 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-02-12 21:54:34 +0000 |
commit | 65f834ad45b2221fd442acc3c38fb2f750521a18 (patch) | |
tree | 15b6f16b11539ae0f7d22b40564efdb7c0424ee4 /actionpack | |
parent | 83c3f6f81a4dbb618518aac9e411cd1f675fe571 (diff) | |
download | rails-65f834ad45b2221fd442acc3c38fb2f750521a18.tar.gz rails-65f834ad45b2221fd442acc3c38fb2f750521a18.tar.bz2 rails-65f834ad45b2221fd442acc3c38fb2f750521a18.zip |
Stringify the parameters on follow_redirect
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@587 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/lib/action_controller/test_process.rb | 2 | ||||
-rw-r--r-- | actionpack/test/controller/action_pack_assertions_test.rb | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/actionpack/lib/action_controller/test_process.rb b/actionpack/lib/action_controller/test_process.rb index 7458230d78..d4dfe7933d 100644 --- a/actionpack/lib/action_controller/test_process.rb +++ b/actionpack/lib/action_controller/test_process.rb @@ -257,7 +257,7 @@ module Test raise "Can't follow redirects outside of current controller (#{@response.redirected_to[:controller]})" end - get(@response.redirected_to.delete(:action), @response.redirected_to) + get(@response.redirected_to.delete(:action), @response.redirected_to.stringify_keys) end end end diff --git a/actionpack/test/controller/action_pack_assertions_test.rb b/actionpack/test/controller/action_pack_assertions_test.rb index 14ca462300..4c0382a32c 100644 --- a/actionpack/test/controller/action_pack_assertions_test.rb +++ b/actionpack/test/controller/action_pack_assertions_test.rb @@ -15,7 +15,7 @@ class ActionPackAssertionsController < ActionController::Base # a redirect to an internal location def redirect_internal() redirect_to "nothing"; end - def redirect_to_action() redirect_to :action => "flash_me"; end + def redirect_to_action() redirect_to :action => "flash_me", :id => 1, :params => { "panda" => "fun" }; end def redirect_to_controller() redirect_to :controller => "elsewhere", :action => "flash_me"; end @@ -352,6 +352,8 @@ class ActionPackAssertionsControllerTest < Test::Unit::TestCase assert_redirected_to :action => "flash_me" follow_redirect + assert_equal 1, @request.parameters["id"] + assert "Inconceivable!", @response.body end |