test/test_rack_hijack.rb in yahns-1.14.0 vs test/test_rack_hijack.rb in yahns-1.14.1
- old
+ new
@@ -84,9 +84,15 @@
h.put("/hijack_input", "BLAH", hdr)
end
assert_equal "rack.input contents: BLAH", res.body
assert_equal 201, res.code.to_i
assert_equal "1.0", res.http_version
+
+ # ancient "HTTP/0.9"
+ c = get_tcp_client(host, port)
+ c.write("GET /hijack_res\r\n\r\n")
+ res = Timeout.timeout(30) { c.read }
+ assert_equal 'response.hijacked', res
ensure
quit_wait(pid)
end
end