diff options
Diffstat (limited to 'ctdb/tests/UNIT/takeover/scripts/local.sh')
-rw-r--r-- | ctdb/tests/UNIT/takeover/scripts/local.sh | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/ctdb/tests/UNIT/takeover/scripts/local.sh b/ctdb/tests/UNIT/takeover/scripts/local.sh new file mode 100644 index 0000000..0db3d90 --- /dev/null +++ b/ctdb/tests/UNIT/takeover/scripts/local.sh @@ -0,0 +1,30 @@ +# Hey Emacs, this is a -*- shell-script -*- !!! :-) + +test_prog="ctdb_takeover_tests ipalloc" + +define_test () +{ + _f=$(basename "$0" ".sh") + + export CTDB_IP_ALGORITHM="${_f%%.*}" + case "$CTDB_IP_ALGORITHM" in + lcp2|nondet|det) : ;; + *) die "Unknown algorithm for testcase \"$_f\"" ;; + esac + + printf "%-12s - %s\n" "$_f" "$1" +} + +extra_footer () +{ + cat <<EOF +-------------------------------------------------- +Algorithm: $CTDB_IP_ALGORITHM +-------------------------------------------------- +EOF +} + +simple_test () +{ + unit_test $VALGRIND $test_prog "$@" +} |