]> err.no Git - varnish/commitdiff
Expand the -repeat 6 in the server clause, this seems to make the
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Tue, 14 Oct 2008 09:15:50 +0000 (09:15 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Tue, 14 Oct 2008 09:15:50 +0000 (09:15 +0000)
test work reliably on my machine.

Also set the reponse text to a recognizable text for improved logreading
should it fail again.

git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@3294 d4fa192b-c00b-0410-8231-f00ffab90ce4

varnish-cache/bin/varnishtest/tests/b00019.vtc

index 2501acbe13e41e8243407ad7a126e5142d8a3e01..3ad08cc1bab36560afd032f269c16fd93b51d4a6 100644 (file)
@@ -2,7 +2,17 @@
 
 test "Check that max_restarts works and that we don't fall over"
 
-server s1 -repeat 6 {
+server s1 {
+       rxreq
+       txresp -body "012345\n"
+       rxreq
+       txresp -body "012345\n"
+       rxreq
+       txresp -body "012345\n"
+       rxreq
+       txresp -body "012345\n"
+       rxreq
+       txresp -body "012345\n"
        rxreq
        txresp -body "012345\n"
 } -start
@@ -15,10 +25,13 @@ varnish v1 -vcl+backend {
        sub vcl_error {
                if (req.restarts == 2) {
                        set obj.status = 200;
+                       set obj.response = "restart=2"; 
                } elsif (req.restarts > 2) {
                        set obj.status = 501;
+                       set obj.response = "restart>2"; 
                } elsif (req.restarts < 2) {
                        set obj.status = 500;
+                       set obj.response = "restart<2"; 
                }
        }
 } -start