[master] 64ccd4464 Test vcl.load failure via vtc cli and varnishadm
Nils Goroll
nils.goroll at uplex.de
Mon Sep 19 13:44:06 UTC 2022
commit 64ccd4464fe7cf04052ee0a288bdbfdb38de2151
Author: Nils Goroll <nils.goroll at uplex.de>
Date: Thu Sep 15 10:32:22 2022 +0200
Test vcl.load failure via vtc cli and varnishadm
diff --git a/bin/varnishtest/tests/m00000.vtc b/bin/varnishtest/tests/m00000.vtc
index cc78c3c1f..a5d94aca4 100644
--- a/bin/varnishtest/tests/m00000.vtc
+++ b/bin/varnishtest/tests/m00000.vtc
@@ -173,6 +173,23 @@ varnish v1 -errvcl {Failed initialization} {
}
}
+shell {
+ cat >${tmpdir}/f1 <<-EOF
+ vcl 4.1;
+ import debug;
+ backend none none;
+ sub vcl_init {
+ new fails = debug.obj("fail");
+ }
+ EOF
+}
+
+varnish v1 -clierr 300 "vcl.load f1 ${tmpdir}/f1"
+
+shell -exit 1 -expect {failing as requested} {
+ varnishadm -n ${tmpdir}/v1 vcl.load f1 ${tmpdir}/f1
+}
+
varnish v1 -cliok "param.set vcc_feature +allow_inline_c"
varnish v1 -vcl {
import vtc;
More information about the varnish-commit
mailing list