aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSantiago Pastorino <santiago@wyeworks.com>2014-08-08 11:33:10 -0300
committerSantiago Pastorino <santiago@wyeworks.com>2014-08-08 11:33:10 -0300
commit7a3d8e20de33bb8a7625d576e80a1c5c7bb061b9 (patch)
treeb7c4590570537c73dbcaf19b9406ad9231f31139
parentf4c8ce9dc816cafa06fc79714623d80bc46a66e5 (diff)
parentaaef6a3860e3952faf551d25076f42ea7f6ff426 (diff)
downloadrails-7a3d8e20de33bb8a7625d576e80a1c5c7bb061b9.tar.gz
rails-7a3d8e20de33bb8a7625d576e80a1c5c7bb061b9.tar.bz2
rails-7a3d8e20de33bb8a7625d576e80a1c5c7bb061b9.zip
Merge pull request #16426 from tgxworld/fix_false_positive
Fixes to TestCaseTest.
-rw-r--r--actionpack/test/controller/test_case_test.rb9
1 files changed, 5 insertions, 4 deletions
diff --git a/actionpack/test/controller/test_case_test.rb b/actionpack/test/controller/test_case_test.rb
index a9ed5021bb..060c940100 100644
--- a/actionpack/test/controller/test_case_test.rb
+++ b/actionpack/test/controller/test_case_test.rb
@@ -713,6 +713,7 @@ XML
def test_header_properly_reset_after_remote_http_request
xhr :get, :test_params
assert_nil @request.env['HTTP_X_REQUESTED_WITH']
+ assert_nil @request.env['HTTP_ACCEPT']
end
def test_header_properly_reset_after_get_request
@@ -721,10 +722,10 @@ XML
assert_nil @request.instance_variable_get("@request_method")
end
- def test_params_reset_after_post_request
+ def test_params_reset_between_post_requests
post :no_op, :foo => "bar"
assert_equal "bar", @request.params[:foo]
- @request.recycle!
+
post :no_op
assert @request.params[:foo].blank?
end
@@ -737,10 +738,10 @@ XML
assert_equal "baz", @request.filtered_parameters[:foo]
end
- def test_path_params_reset_after_request
+ def test_path_params_reset_between_request
get :test_params, :id => "foo"
assert_equal "foo", @request.path_parameters[:id]
- @request.recycle!
+
get :test_params
assert_nil @request.path_parameters[:id]
end