From 1195075117f41eb8b98d129acd7b196b0ce94f8d Mon Sep 17 00:00:00 2001 From: phk Date: Fri, 27 Jun 2008 12:30:42 +0000 Subject: [PATCH] Add testcase for pipelining git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@2851 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- .../bin/varnishtest/tests/b00012.vtc | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 varnish-cache/bin/varnishtest/tests/b00012.vtc diff --git a/varnish-cache/bin/varnishtest/tests/b00012.vtc b/varnish-cache/bin/varnishtest/tests/b00012.vtc new file mode 100644 index 00000000..f3a5e71e --- /dev/null +++ b/varnish-cache/bin/varnishtest/tests/b00012.vtc @@ -0,0 +1,34 @@ +# $Id$ + +test "Check pipelining" + +varnish v1 -arg "-h simple_list -b 127.0.0.1:9080" -start + +server s1 { + rxreq + expect req.url == "/foo" + txresp -body "foo" + rxreq + expect req.url == "/bar" + txresp -body "foobar" +} + +server s1 -start + +client c1 { + send "GET /foo HTTP/1.1\n\nGET /bar HTTP/1.1\n\nGET /bar HTTP/1.1\n\n" + rxresp + expect resp.status == 200 + expect resp.http.content-length == 3 + expect resp.http.x-varnish == "1001" + rxresp + expect resp.status == 200 + expect resp.http.content-length == 6 + expect resp.http.x-varnish == "1002" + rxresp + expect resp.status == 200 + expect resp.http.content-length == 6 + expect resp.http.x-varnish == "1003 1002" +} + +client c1 -run -- 2.39.5