r3691 - branches/2.0/varnish-cache/bin/varnishtest/tests

tfheen at projects.linpro.no tfheen at projects.linpro.no
Fri Feb 6 16:31:03 CET 2009


Author: tfheen
Date: 2009-02-06 16:31:03 +0100 (Fri, 06 Feb 2009)
New Revision: 3691

Added:
   branches/2.0/varnish-cache/bin/varnishtest/tests/c00020.vtc
Log:
Merge r3503: Add a minimal testcase of critbit



Copied: branches/2.0/varnish-cache/bin/varnishtest/tests/c00020.vtc (from rev 3503, trunk/varnish-cache/bin/varnishtest/tests/c00020.vtc)
===================================================================
--- branches/2.0/varnish-cache/bin/varnishtest/tests/c00020.vtc	                        (rev 0)
+++ branches/2.0/varnish-cache/bin/varnishtest/tests/c00020.vtc	2009-02-06 15:31:03 UTC (rev 3691)
@@ -0,0 +1,32 @@
+# $Id$
+
+test "Test -h critbit a bit"
+
+server s1 {
+        rxreq 
+        txresp -hdr "Connection: close" -body "012345\n"
+} -start
+
+varnish v1 -arg "-hcritbit" -vcl+backend { } -start 
+
+client c1 {
+        txreq -url "/"
+        rxresp
+        expect resp.status == 200
+        expect resp.http.X-Varnish == "1001"
+} -run
+
+client c2 {
+        txreq -url "/"
+        rxresp
+        expect resp.status == 200
+        expect resp.http.X-Varnish == "1002 1001"
+} -run
+
+varnish v1 -expect client_conn == 2
+varnish v1 -expect cache_hit == 1
+varnish v1 -expect cache_miss == 1
+varnish v1 -expect client_req == 2
+varnish v1 -expect s_sess == 2
+varnish v1 -expect s_req == 2
+varnish v1 -expect s_fetch == 1



More information about the varnish-commit mailing list