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

phk at projects.linpro.no phk at projects.linpro.no
Fri Jun 27 14:58:46 CEST 2008


Author: phk
Date: 2008-06-27 14:58:46 +0200 (Fri, 27 Jun 2008)
New Revision: 2856

Added:
   trunk/varnish-cache/bin/varnishtest/tests/c00012.vtc
Log:
test miss from pass



Added: trunk/varnish-cache/bin/varnishtest/tests/c00012.vtc
===================================================================
--- trunk/varnish-cache/bin/varnishtest/tests/c00012.vtc	                        (rev 0)
+++ trunk/varnish-cache/bin/varnishtest/tests/c00012.vtc	2008-06-27 12:58:46 UTC (rev 2856)
@@ -0,0 +1,33 @@
+# $Id$
+
+test "Test pass from miss"
+
+server s1 {
+	rxreq
+	expect req.url == "/foo"
+	txresp -body foobar
+	rxreq
+	expect req.url == "/foo"
+	txresp -body foobar1
+} -start
+
+varnish v1 -vcl+backend { 
+	sub vcl_miss {
+		pass;
+	}
+} -start
+
+client c1 {
+	txreq -url "/foo"
+	rxresp
+	expect resp.status == 200
+	expect resp.http.content-length == 6
+	expect resp.http.x-varnish == "1001"
+	txreq -url "/foo"
+	rxresp
+	expect resp.status == 200
+	expect resp.http.content-length == 7
+	expect resp.http.x-varnish == "1002"
+} 
+
+client c1 -run




More information about the varnish-commit mailing list