diff options
author | Martin Schwenke <martin@meltin.net> | 2013-07-22 20:11:58 +1000 |
---|---|---|
committer | Amitay Isaacs <amitay@gmail.com> | 2013-07-29 15:49:23 +1000 |
commit | 34d55048bc21005b7e5b15a8ceca1a0f6377a024 (patch) | |
tree | 9585e7d021f23217b01ec0503cabc584f53d84ab /ctdb/tests | |
parent | f46ab595d1ca09915e8fd754ec1783dc73cfb823 (diff) | |
download | samba-34d55048bc21005b7e5b15a8ceca1a0f6377a024.tar.gz samba-34d55048bc21005b7e5b15a8ceca1a0f6377a024.tar.xz samba-34d55048bc21005b7e5b15a8ceca1a0f6377a024.zip |
tests: Always tally the number of passed/failed tests
Regardless of whether a summary is being printed!
Signed-off-by: Martin Schwenke <martin@meltin.net>
(This used to be ctdb commit a69e03a5e4671e998d45b4fef8611a421bbdb3e1)
Diffstat (limited to 'ctdb/tests')
-rwxr-xr-x | ctdb/tests/scripts/run_tests | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/ctdb/tests/scripts/run_tests b/ctdb/tests/scripts/run_tests index 719a16e52a4..171e8197f72 100755 --- a/ctdb/tests/scripts/run_tests +++ b/ctdb/tests/scripts/run_tests @@ -175,13 +175,16 @@ run_one_test () ctdb_test_run "$_f" | tee "$tf" | show_progress status=$? + if [ $status -eq 0 ] ; then + tests_passed=$(($tests_passed + 1)) + else + tests_failed=$(($tests_failed + 1)) + fi if $with_summary ; then if [ $status -eq 0 ] ; then - tests_passed=$(($tests_passed + 1)) _t=" PASSED " else _t="*FAILED*" - tests_failed=$(($tests_failed + 1)) fi if $with_desc ; then desc=$(tail -n +4 $tf | head -n 1) |