diff options
author | Luca Deri <deri@ntop.org> | 2023-02-27 12:20:15 +0100 |
---|---|---|
committer | Luca Deri <deri@ntop.org> | 2023-02-27 12:20:15 +0100 |
commit | 807c97344fc754df991cbb810e8a00d4729ebaaf (patch) | |
tree | c232c72b7597f0f8cdedc57e7830e16f38e465e9 | |
parent | 96f0f85e56a61fe26b240c3a0b68dcbf69a66e75 (diff) |
in case of failure, failing result files are not listed
-rwxr-xr-x | tests/do.sh.in | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/do.sh.in b/tests/do.sh.in index 94d2b3fc0..b69ead419 100755 --- a/tests/do.sh.in +++ b/tests/do.sh.in @@ -29,6 +29,7 @@ READER="${CMD_PREFIX} ../example/ndpiReader${EXE_SUFFIX} -A -p ../example/protos RC=0 PCAPS=`cd pcap; /bin/ls *.pcap *.pcapng *.cap` +FAILURES=() if [ ! -x "../example/ndpiReader${EXE_SUFFIX}" ]; then echo "$0: Missing ../example/ndpiReader${EXE_SUFFIX}" @@ -110,6 +111,7 @@ check_results() { else printf "%-48s\tERROR (ndpiReader${EXE_SUFFIX} exit code: ${CMD_RET})\n" "$f" RC=$(( RC + 1 )) + FAILURES+=("$f.out") continue fi @@ -123,6 +125,7 @@ check_results() { ${CMD_WDIFF} -n -3 result/$f.out /tmp/reader.$$.out | sort | uniq | ${CMD_COLORDIFF} fi RC=$(( RC + 1 )) + FAILURES+=("$f.out") fi /bin/rm -f /tmp/reader.$$.out @@ -145,5 +148,5 @@ build_results check_results $* test ${RC} -ne 0 && printf '%s: %s\n' "${0}" "${RC} pcap(s) failed" - +test ${RC} -ne 0 && echo "Failed: ${FAILURES[@]}" exit $RC |