]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
When a prereq.sh file determines that a test can't run because the feature
authorEvan Hunt <each@isc.org>
Mon, 20 Dec 2010 21:35:45 +0000 (21:35 +0000)
committerEvan Hunt <each@isc.org>
Mon, 20 Dec 2010 21:35:45 +0000 (21:35 +0000)
to be tested was not configured in at build time, it can now return 255,
and run.sh will print "R:SKIPPED" instead of "R:UNTESTED".  Robie will be
able to flag this as green rather than yellow.

bin/tests/system/dlzexternal/prereq.sh
bin/tests/system/run.sh
bin/tests/system/tsiggss/prereq.sh

index 9791692989ec3a4e302a89bf45c95992dc670958..bc7df46a3d2f57ae8281eaae9d0c9046da2efe44 100644 (file)
@@ -5,7 +5,7 @@ TOP=${SYSTEMTESTTOP:=.}/../../../..
 # enable the dlzexternal test only if it builds and dlz-dlopen was enabled
 $TOP/bin/named/named -V | grep with.dlz.dlopen | grep -v with.dlz.dlopen=no > /dev/null || {
     echo "I:not built with --with-dlz-dlopen=yes - skipping dlzexternal test"
-    exit 1
+    exit 255
 }
 
 cd ../../../../contrib/dlz/example && make all > /dev/null || {
index a4911c5fc2eb04d23d1be09cb90f613c0f84cf1f..4b79eafc58349850fb9ed546aa5a0bb9aab6e0fd 100644 (file)
@@ -15,7 +15,7 @@
 # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
 # PERFORMANCE OF THIS SOFTWARE.
 
-# $Id: run.sh,v 1.44 2010/06/08 23:50:24 tbox Exp $
+# $Id: run.sh,v 1.45 2010/12/20 21:35:45 each Exp $
 
 #
 # Run a system test.
@@ -58,14 +58,14 @@ $PERL testsock.pl || {
 
 
 # Check for test-specific prerequisites.
-if
-    test ! -f $test/prereq.sh ||
-    ( cd $test && sh prereq.sh "$@" )
-then
+test ! -f $test/prereq.sh || ( cd $test && sh prereq.sh "$@" )
+result=$?
+
+if [ $result -eq 0 ]; then
     : prereqs ok
 else
     echo "I:Prerequisites for $test missing, skipping test." >&2
-    echo "R:UNTESTED" >&2
+    [ $result -eq 255 ] && echo "R:SKIPPED" || echo "R:UNTESTED"
     echo "E:$test:`date`" >&2
     exit 0
 fi
index 2c1a32a3d5c1d2f0f034486888f98dfe3611899e..0b0fe756e5286976ab1e5d1ad21e7dbd4488ec45 100644 (file)
@@ -5,7 +5,7 @@ TOP=${SYSTEMTESTTOP:=.}/../../../..
 # enable the tsiggss test only if gssapi was enabled
 $TOP/bin/named/named -V | grep with.gssapi | grep -v with-gssapi=no > /dev/null || {
     echo "I:BIND9 was not built with --with-gssapi"
-    exit 1
+    exit 255
 }
 
 exit 0