diff options
author | David Howells <dhowells@redhat.com> | 2014-03-06 15:10:04 +0000 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2014-03-06 15:10:04 +0000 |
commit | 25897132d436c6c8986a70e283e6da84fe52ae74 (patch) | |
tree | cacadde7ef37d9a88ce42045fedafd70ca820c7f | |
parent | 734e6a13b3f2954791c5f4dd5c572524fb87bd29 (diff) | |
download | keyutils-25897132d436c6c8986a70e283e6da84fe52ae74.tar.gz |
TEST: Add function to record skipped tests
Add a function to the toolbox to record skipped tests.
Signed-off-by: David Howells <dhowells@redhat.com>
-rw-r--r-- | tests/keyctl/unlink/all/runtest.sh | 4 | ||||
-rw-r--r-- | tests/toolbox.inc.sh | 11 |
2 files changed, 9 insertions, 6 deletions
diff --git a/tests/keyctl/unlink/all/runtest.sh b/tests/keyctl/unlink/all/runtest.sh index 20a77f5..24aaa3f 100644 --- a/tests/keyctl/unlink/all/runtest.sh +++ b/tests/keyctl/unlink/all/runtest.sh @@ -95,8 +95,8 @@ then echo "++++ FINISHED TEST: $result" >>$OUTPUTFILE else - echo "++++ SKIPPING TEST" >>$OUTPUTFILE - marker SKIP on version + toolbox_skip_test $TEST "SKIPPING TEST DUE TO LACK OF UNLINK-ALL" + exit 0 fi # --- then report the results in the database --- diff --git a/tests/toolbox.inc.sh b/tests/toolbox.inc.sh index 945d193..332bcd6 100644 --- a/tests/toolbox.inc.sh +++ b/tests/toolbox.inc.sh @@ -80,6 +80,12 @@ function toolbox_report_result() fi } +function toolbox_skip_test() +{ + echo "++++ SKIPPING TEST" >>$OUTPUTFILE + marker "$2" + toolbox_report_result $1 PASS +} ############################################################################### # @@ -92,10 +98,7 @@ function require_command () which "$1" >&/dev/null if [ $? != 0 ] then - echo "++++ SKIPPING TEST" >>$OUTPUTFILE - marker "SKIP DUE TO MISSING COMMAND: $1" - toolbox_report_result $TEST PASS - + toolbox_skip_test "SKIP DUE TO MISSING COMMAND: $1" exit 0 fi } |