diff options
author | Eric Wong <normalperson@yhbt.net> | 2011-01-05 14:06:00 -0800 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2011-01-05 15:09:05 -0800 |
commit | 62c844e343978f233e4f2567fb344411c39e263c (patch) | |
tree | 00f196f0c7a20fc43f92568ae0c8e1b6cb83c9b9 /test/unit/test_http_parser_ng.rb | |
parent | bd397ee11b60243ef15c5558c4309e46e27e6192 (diff) | |
download | unicorn-62c844e343978f233e4f2567fb344411c39e263c.tar.gz |
But allows small optimizations to be made to avoid constant/instance variable lookups later :)
Diffstat (limited to 'test/unit/test_http_parser_ng.rb')
-rw-r--r-- | test/unit/test_http_parser_ng.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/unit/test_http_parser_ng.rb b/test/unit/test_http_parser_ng.rb index e080d9c..b60afdf 100644 --- a/test/unit/test_http_parser_ng.rb +++ b/test/unit/test_http_parser_ng.rb @@ -91,7 +91,7 @@ class HttpParserNgTest < Test::Unit::TestCase @parser.parse end assert @parser.keepalive? - @parser.reset + @parser.clear assert ! @parser.keepalive? assert ! @parser.next? end @@ -491,7 +491,7 @@ class HttpParserNgTest < Test::Unit::TestCase }.each do |uri,expect| assert_equal req, @parser.headers(req.clear, str % [ uri ]) req = req.dup - @parser.reset + @parser.clear assert_equal uri, req["REQUEST_URI"], "REQUEST_URI mismatch" assert_equal expect[qs], req[qs], "#{qs} mismatch" assert_equal expect[pi], req[pi], "#{pi} mismatch" @@ -516,7 +516,7 @@ class HttpParserNgTest < Test::Unit::TestCase }.each do |uri,expect| assert_equal req, @parser.headers(req.clear, str % [ uri ]) req = req.dup - @parser.reset + @parser.clear assert_equal uri, req["REQUEST_URI"], "REQUEST_URI mismatch" assert_equal "example.com", req["HTTP_HOST"], "Host: mismatch" assert_equal expect[qs], req[qs], "#{qs} mismatch" |