From a51ca6d85167227c5fe0a87e40780008400d4380 Mon Sep 17 00:00:00 2001 From: tfheen Date: Wed, 25 Feb 2009 10:50:49 +0000 Subject: [PATCH] Make sure system "..." returns successfully We didn't check the return status of system, making failures in a00009 go unnoticed. Fix this and fix a00009 to not fail when run uninstalled. git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@3826 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- varnish-cache/bin/varnishtest/tests/a00009.vtc | 2 +- varnish-cache/bin/varnishtest/vtc.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/varnish-cache/bin/varnishtest/tests/a00009.vtc b/varnish-cache/bin/varnishtest/tests/a00009.vtc index 85dcce9d..b3c89e73 100644 --- a/varnish-cache/bin/varnishtest/tests/a00009.vtc +++ b/varnish-cache/bin/varnishtest/tests/a00009.vtc @@ -2,4 +2,4 @@ test "See that the VCL compiler works" -shell "cd ../varnishd && ./varnishd -b 127.0.0.1:80 -C" +shell "cd ../varnishd && ./varnishd -b 127.0.0.1:80 -C -n /tmp/__v1" diff --git a/varnish-cache/bin/varnishtest/vtc.c b/varnish-cache/bin/varnishtest/vtc.c index 31732613..2bd12426 100644 --- a/varnish-cache/bin/varnishtest/vtc.c +++ b/varnish-cache/bin/varnishtest/vtc.c @@ -246,7 +246,7 @@ cmd_shell(CMD_ARGS) AN(av[1]); AZ(av[2]); vtc_dump(vl, 4, "shell", av[1]); - (void)system(av[1]); /* XXX: assert ? */ + assert(WEXITSTATUS(system(av[1])) == 0); } /********************************************************************** -- 2.39.5