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

tfheen at varnish-cache.org tfheen at varnish-cache.org
Wed Oct 27 12:24:11 CEST 2010


Author: tfheen
Date: 2010-10-27 12:24:11 +0200 (Wed, 27 Oct 2010)
New Revision: 5473

Removed:
   trunk/varnish-cache/bin/varnishtest/tests/r00663.vtc
Log:
Remove r00663, this test is flaky and should be unneeded.


Deleted: trunk/varnish-cache/bin/varnishtest/tests/r00663.vtc
===================================================================
--- trunk/varnish-cache/bin/varnishtest/tests/r00663.vtc	2010-10-27 10:04:15 UTC (rev 5472)
+++ trunk/varnish-cache/bin/varnishtest/tests/r00663.vtc	2010-10-27 10:24:11 UTC (rev 5473)
@@ -1,84 +0,0 @@
-# for emacs, -*- perl -*- comes closest to VTC syntax
-# $Id$
-
-test "Test that errno is thread-local"
-
-server s1 {
-	rxreq
-	txresp -bodylen 1
-	sema r1 sync 2
-	rxreq
-	txresp -bodylen 2
-} -start
-
-varnish v1 -vcl+backend {
-    C{
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <fcntl.h>
-#include <stdio.h>
-#include <unistd.h>
-#include <errno.h>
-    }C
-
-	# create a race between two requests to see if errno behaves
-	# thread-local: The first client triggers an error and then
-	# sleeps. the second client should win the race and clear its
-	# errno
-
-    sub vcl_deliver {
-	if (req.http.client == "one") {
-	    C{
-		char buf[16];
-		int fd;
-		
-		fd = open("/foobar/dont/tell/me/this/path/really/exists/"
-			  "on/your/system/by/purpose", O_RDONLY);
-		
-		sleep(2);
-		
-		sprintf(buf, "%d", errno);
-		
-		VRT_SetHdr(sp, HDR_RESP, "\006errno:", buf, vrt_magic_string_end);
-		
-		if (fd)
-		    close(fd);
-	    }C
-	} elsif (req.http.client == "two") {
-	    C{
-		char buf[16];
-		int fd;
-		
-		fd = open("/dev/null", O_RDONLY);
-		
-		sprintf(buf, "%d", errno);
-		
-		VRT_SetHdr(sp, HDR_RESP, "\006errno:", buf, vrt_magic_string_end);
-		
-		if (fd)
-		    close(fd);
-	    }C
-    	} else {
-	    error 505 "invalid client header";
-    	}
-    }
-} -start
-
-client c1 {
-    	txreq -url "/one" -hdr "Client: one"
-	rxresp
-        expect resp.status == 200
-        expect resp.http.X-Varnish == "1001"
-	expect resp.http.errno != "0"
-} -start
-
-client c2 {
-	sema r1 sync 2
-	txreq -url "/two" -hdr "Client: two"
-	rxresp
-        expect resp.status == 200
-        expect resp.http.X-Varnish == "1002"
-	expect resp.http.errno == "0"
-} -run
-
-client c1 -wait




More information about the varnish-commit mailing list