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

phk at projects.linpro.no phk at projects.linpro.no
Mon Jul 7 19:19:10 CEST 2008


Author: phk
Date: 2008-07-07 19:19:10 +0200 (Mon, 07 Jul 2008)
New Revision: 2880

Added:
   trunk/varnish-cache/bin/varnishtest/tests/v00002.vtc
Log:
Add test-case or syntax-checks of backend decls.



Added: trunk/varnish-cache/bin/varnishtest/tests/v00002.vtc
===================================================================
--- trunk/varnish-cache/bin/varnishtest/tests/v00002.vtc	                        (rev 0)
+++ trunk/varnish-cache/bin/varnishtest/tests/v00002.vtc	2008-07-07 17:19:10 UTC (rev 2880)
@@ -0,0 +1,36 @@
+# $Id$
+
+test "VCL: test syntax/semantic checks on backend decls."
+
+# Missing .host
+varnish v1 -badvcl {
+	backend b1 {
+		.port = "http";
+	}
+}
+
+# Too many .host
+varnish v1 -badvcl {
+	backend b1 {
+		.host = "foo";
+		.host = "bar";
+	}
+}
+
+# Too many .port
+varnish v1 -badvcl {
+	backend b1 {
+		.host = "foo";
+		.port = "http";
+		.port = "https";
+	}
+}
+
+# Too many .connect_timeout
+varnish v1 -badvcl {
+	backend b1 {
+		.host = "foo";
+		.connect_timeout = 1m;
+		.connect_timeout = 1m;
+	}
+}




More information about the varnish-commit mailing list