r4544 - trunk/varnish-cache/bin/varnishtest/tests

phk at projects.linpro.no phk at projects.linpro.no
Wed Feb 10 11:35:50 CET 2010


Author: phk
Date: 2010-02-10 11:35:49 +0100 (Wed, 10 Feb 2010)
New Revision: 4544

Added:
   trunk/varnish-cache/bin/varnishtest/tests/r00495.vtc
Log:
Add regression test for #495



Added: trunk/varnish-cache/bin/varnishtest/tests/r00495.vtc
===================================================================
--- trunk/varnish-cache/bin/varnishtest/tests/r00495.vtc	                        (rev 0)
+++ trunk/varnish-cache/bin/varnishtest/tests/r00495.vtc	2010-02-10 10:35:49 UTC (rev 4544)
@@ -0,0 +1,44 @@
+# $Id$
+
+test "HTTP 1.0 backend not getting reused"
+
+
+server s1 {
+	rxreq
+	txresp -proto HTTP/1.0 -status 201 -hdr "Connection: keep-alive" -body foo
+
+	rxreq
+	txresp -proto HTTP/1.0 -status 202 -hdr "Connection: close" -body foo
+
+	expect_close
+	accept
+
+	rxreq
+	txresp -proto HTTP/1.0 -status 203 -body foo
+
+	expect_close
+	accept
+
+	rxreq
+	txresp -proto HTTP/1.0 -status 204 -body bar
+
+} -start
+
+varnish v1 -vcl+backend {
+	sub vcl_recv { return (pass); }
+} -start
+
+client c1 {
+	txreq
+	rxresp
+	expect resp.status == 201
+	txreq 
+	rxresp
+	expect resp.status == 202
+	txreq 
+	rxresp
+	expect resp.status == 203
+	txreq 
+	rxresp
+	expect resp.status == 204
+} -run



More information about the varnish-commit mailing list