]> err.no Git - varnish/commitdiff
More VCL compiler coverage tests
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Fri, 10 Oct 2008 21:43:02 +0000 (21:43 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Fri, 10 Oct 2008 21:43:02 +0000 (21:43 +0000)
git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@3288 d4fa192b-c00b-0410-8231-f00ffab90ce4

varnish-cache/bin/varnishtest/tests/v00021.vtc [new file with mode: 0644]

diff --git a/varnish-cache/bin/varnishtest/tests/v00021.vtc b/varnish-cache/bin/varnishtest/tests/v00021.vtc
new file mode 100644 (file)
index 0000000..0a95dfe
--- /dev/null
@@ -0,0 +1,52 @@
+# $Id$
+
+test "VCL compiler coverage test: vcc_xref.c"
+
+varnish v1 -badvcl {
+       backend b { .host = "127.0.0.1"; }
+       sub vcl_recv { set obj.ttl = 1 w; }
+}
+
+varnish v1 -badvcl {
+       backend b { .host = "127.0.0.1"; }
+
+       sub foo { set obj.ttl = 1 w; }
+       sub vcl_recv { call foo ; }
+}
+
+varnish v1 -badvcl {
+       backend b { .host = "127.0.0.1"; }
+
+       sub vcl_recv { discard; }
+}
+
+varnish v1 -badvcl {
+       backend b { .host = "127.0.0.1"; }
+
+       sub foo { discard; }
+       sub vcl_recv { call foo; }
+}
+
+varnish v1 -badvcl {
+       backend b { .host = "127.0.0.1"; }
+
+       sub foo { call foo; }
+       sub vcl_recv { call foo; }
+}
+
+varnish v1 -badvcl {
+       backend b { .host = "127.0.0.1"; }
+
+       sub bar { call foo; }
+       sub foo { call bar; }
+       sub vcl_recv { call foo; }
+}
+
+
+varnish v1 -badvcl {
+       backend b { .host = "127.0.0.1"; }
+
+       acl foo { "localhost"; }
+
+}
+