Permalink
Browse files

change tests to expect X-F-F over REMOTE_ADDR

  • Loading branch information...
indirect committed Nov 13, 2011
1 parent e0efe48 commit 8f0085a483ebc6d416e902c3caff68f82934e091
Showing with 2 additions and 2 deletions.
  1. +2 −2 actionpack/test/dispatch/request_test.rb
@@ -36,7 +36,7 @@ def url_for(options = {})
request = stub_request 'REMOTE_ADDR' => '1.2.3.4',
'HTTP_X_FORWARDED_FOR' => '3.4.5.6'
- assert_equal '1.2.3.4', request.remote_ip
+ assert_equal '3.4.5.6', request.remote_ip
request = stub_request 'REMOTE_ADDR' => '127.0.0.1',
'HTTP_X_FORWARDED_FOR' => '3.4.5.6'
@@ -106,7 +106,7 @@ def url_for(options = {})
request = stub_request 'REMOTE_ADDR' => '67.205.106.74,172.16.0.1',
'HTTP_X_FORWARDED_FOR' => '3.4.5.6'
- assert_equal '67.205.106.74', request.remote_ip
+ assert_equal '3.4.5.6', request.remote_ip
request = stub_request 'HTTP_X_FORWARDED_FOR' => 'unknown,67.205.106.73'
assert_equal 'unknown', request.remote_ip

0 comments on commit 8f0085a

Please sign in to comment.