aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_controller/test_case.rb
diff options
context:
space:
mode:
authorGeorge Claghorn <george.claghorn@gmail.com>2018-04-30 22:48:10 -0400
committerGitHub <noreply@github.com>2018-04-30 22:48:10 -0400
commita42fb70a152ee05725685a8f68e3e8e2ddda4b36 (patch)
treee5a75fc09dc4cc2bc450ccf609a5011e01059497 /actionpack/lib/action_controller/test_case.rb
parentfd9fa7d41f3cc7f5277dfc670ea958673115a1f2 (diff)
parentf9e14b02c460a1963b350fb5e0e10c0e71ee175c (diff)
downloadrails-a42fb70a152ee05725685a8f68e3e8e2ddda4b36.tar.gz
rails-a42fb70a152ee05725685a8f68e3e8e2ddda4b36.tar.bz2
rails-a42fb70a152ee05725685a8f68e3e8e2ddda4b36.zip
Merge pull request #32773 from eugeneius/content_length_multiple_requests
Reset CONTENT_LENGTH between test requests
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 8f2a7e2b5f..5d784ceb31 100644
--- a/actionpack/lib/action_controller/test_case.rb
+++ b/actionpack/lib/action_controller/test_case.rb
@@ -604,6 +604,7 @@ module ActionController
env.delete "action_dispatch.request.query_parameters"
env.delete "action_dispatch.request.request_parameters"
env["rack.input"] = StringIO.new
+ env.delete "CONTENT_LENGTH"
env.delete "RAW_POST_DATA"
env
end