aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/dispatch
diff options
context:
space:
mode:
authorJosé Valim <jose.valim@gmail.com>2010-09-29 10:04:42 +0200
committerJosé Valim <jose.valim@gmail.com>2010-09-29 10:04:42 +0200
commit0bbf9029e8089356aed0e3be2f859d56951a89cf (patch)
tree38e41ef8b63140a91c828bec03e06e83f38899b6 /actionpack/test/dispatch
parent006cef7107b648882cfc09f56904c601454cfc77 (diff)
parent17599abc9c06f30ff23d7ad47a3f029e32c26c88 (diff)
downloadrails-0bbf9029e8089356aed0e3be2f859d56951a89cf.tar.gz
rails-0bbf9029e8089356aed0e3be2f859d56951a89cf.tar.bz2
rails-0bbf9029e8089356aed0e3be2f859d56951a89cf.zip
Merge remote branch 'miloops/warnings'
Diffstat (limited to 'actionpack/test/dispatch')
-rw-r--r--actionpack/test/dispatch/mime_type_test.rb1
-rw-r--r--actionpack/test/dispatch/request/multipart_params_parsing_test.rb2
-rw-r--r--actionpack/test/dispatch/request/xml_params_parsing_test.rb1
-rw-r--r--actionpack/test/dispatch/request_test.rb1
4 files changed, 3 insertions, 2 deletions
diff --git a/actionpack/test/dispatch/mime_type_test.rb b/actionpack/test/dispatch/mime_type_test.rb
index 369212e2d0..4c2b95550c 100644
--- a/actionpack/test/dispatch/mime_type_test.rb
+++ b/actionpack/test/dispatch/mime_type_test.rb
@@ -41,7 +41,6 @@ class MimeTypeTest < ActiveSupport::TestCase
begin
Mime::Type.register("image/gif", :gif)
assert_nothing_raised do
- Mime::GIF
assert_equal Mime::GIF, Mime::SET.last
end
ensure
diff --git a/actionpack/test/dispatch/request/multipart_params_parsing_test.rb b/actionpack/test/dispatch/request/multipart_params_parsing_test.rb
index 1ae514ebf7..073dd3ddad 100644
--- a/actionpack/test/dispatch/request/multipart_params_parsing_test.rb
+++ b/actionpack/test/dispatch/request/multipart_params_parsing_test.rb
@@ -68,7 +68,7 @@ class MultipartParamsParsingTest < ActionDispatch::IntegrationTest
assert_equal 'file.txt', file.original_filename
assert_equal "text/plain", file.content_type
- assert ('a' * 20480) == file.read
+ assert_equal(('a' * 20480), file.read)
end
test "parses binary file" do
diff --git a/actionpack/test/dispatch/request/xml_params_parsing_test.rb b/actionpack/test/dispatch/request/xml_params_parsing_test.rb
index 16669614d6..ad9de02eb4 100644
--- a/actionpack/test/dispatch/request/xml_params_parsing_test.rb
+++ b/actionpack/test/dispatch/request/xml_params_parsing_test.rb
@@ -18,6 +18,7 @@ class XmlParamsParsingTest < ActionDispatch::IntegrationTest
test "parses a strict rack.input" do
class Linted
+ undef call if method_defined?(:call)
def call(env)
bar = env['action_dispatch.request.request_parameters']['foo']
result = "<ok>#{bar}</ok>"
diff --git a/actionpack/test/dispatch/request_test.rb b/actionpack/test/dispatch/request_test.rb
index a53d4f1edd..3efed8bef6 100644
--- a/actionpack/test/dispatch/request_test.rb
+++ b/actionpack/test/dispatch/request_test.rb
@@ -474,6 +474,7 @@ protected
def stub_request(env = {})
ip_spoofing_check = env.key?(:ip_spoofing_check) ? env.delete(:ip_spoofing_check) : true
+ @trusted_proxies ||= nil
ip_app = ActionDispatch::RemoteIp.new(Proc.new { }, ip_spoofing_check, @trusted_proxies)
tld_length = env.key?(:tld_length) ? env.delete(:tld_length) : 1
ip_app.call(env)