summaryrefslogtreecommitdiff
path: root/selftest
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-10-19 14:49:17 +1100
committerAndrew Tridgell <tridge@samba.org>2010-10-19 14:53:39 +1100
commit75d57dbc25738bcf01d404b329fda22641a774ff (patch)
tree39a601227bd832b07b5080d098e8c46d6e9ef173 /selftest
parentf6a9708b546ac54a74c8718aedd9e5ac976fc72b (diff)
downloadsamba-75d57dbc25738bcf01d404b329fda22641a774ff.tar.gz
samba-75d57dbc25738bcf01d404b329fda22641a774ff.tar.bz2
samba-75d57dbc25738bcf01d404b329fda22641a774ff.zip
selftest: terminate selftest if we can't setup the environment
Diffstat (limited to 'selftest')
-rwxr-xr-xselftest/selftest.pl5
1 files changed, 3 insertions, 2 deletions
diff --git a/selftest/selftest.pl b/selftest/selftest.pl
index 7431bed8ed..eabee7a766 100755
--- a/selftest/selftest.pl
+++ b/selftest/selftest.pl
@@ -253,7 +253,7 @@ sub run_testsuite($$$$$)
if ($? == -1) {
Subunit::progress_pop();
Subunit::end_testsuite($name, "error", "Unable to run $cmd: $!");
- return 0;
+ exit(1);
} elsif ($? & 127) {
Subunit::end_testsuite($name, "error",
sprintf("%s died with signal %d, %s coredump\n", $cmd, ($? & 127), ($? & 128) ? 'with' : 'without'));
@@ -953,7 +953,8 @@ $envvarstr
if (not defined($envvars)) {
Subunit::start_testsuite($name);
Subunit::end_testsuite($name, "error",
- "unable to set up environment $envname");
+ "unable to set up environment $envname - exiting");
+ exit(1);
next;
}