aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_controller/test_case.rb
diff options
context:
space:
mode:
authorGuillermo Iguaran <guilleiguaran@gmail.com>2016-07-28 16:27:44 -0500
committerGitHub <noreply@github.com>2016-07-28 16:27:44 -0500
commit3916656f8e9700eb5f1cfc441ff66e1f12173683 (patch)
tree5b0e2c7a7c8ef392eb6869334c5c98b13097778a /actionpack/lib/action_controller/test_case.rb
parentb37bd3d52f4d06ec3452bdfcd6bc9c6bfcb27519 (diff)
parent273a691dfd6f77a79ce99f50905024fcdc02e67f (diff)
downloadrails-3916656f8e9700eb5f1cfc441ff66e1f12173683.tar.gz
rails-3916656f8e9700eb5f1cfc441ff66e1f12173683.tar.bz2
rails-3916656f8e9700eb5f1cfc441ff66e1f12173683.zip
Merge pull request #25965 from nicksieger/ac_test_case_reset_rack_input
Reset rack.input when the environment is scrubbed for the next request
Diffstat (limited to 'actionpack/lib/action_controller/test_case.rb')
-rw-r--r--actionpack/lib/action_controller/test_case.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/actionpack/lib/action_controller/test_case.rb b/actionpack/lib/action_controller/test_case.rb
index b1b3e87934..6c5d7b5e37 100644
--- a/actionpack/lib/action_controller/test_case.rb
+++ b/actionpack/lib/action_controller/test_case.rb
@@ -620,6 +620,7 @@ module ActionController
env.delete_if { |k, v| k =~ /^action_dispatch\.rescue/ }
env.delete 'action_dispatch.request.query_parameters'
env.delete 'action_dispatch.request.request_parameters'
+ env['rack.input'] = StringIO.new
env
end