From e9e7a1c7c1778ed7cd7c724b26362d1f89b2801c Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Wed, 15 Jun 2011 00:56:47 +0000 Subject: test_http_parser: fix for URI too long errors (again) The random garbage generator may occasionally generate URIs that are too long and cause the URI-specific error to be raised instead of the generic parser error we recently introduced. Follow-up-to: commit 742c4d77f179a757dbcb1fa350f9d75b757acfc7 --- test/unit/test_http_parser.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/unit/test_http_parser.rb b/test/unit/test_http_parser.rb index e6a990d..15e1745 100644 --- a/test/unit/test_http_parser.rb +++ b/test/unit/test_http_parser.rb @@ -761,7 +761,7 @@ class HttpParserTest < Test::Unit::TestCase get = "GET /#{rand_data(10,120)} HTTP/1.1\r\n" get << "X-Test: test\r\n" * (80 * 1024) parser.buf << get - assert_raises Unicorn::HttpParserError do + assert_raises(Unicorn::HttpParserError,Unicorn::RequestURITooLongError) do parser.parse end parser.clear -- cgit v1.2.3-24-ge0c7