From 807c97344fc754df991cbb810e8a00d4729ebaaf Mon Sep 17 00:00:00 2001 From: Luca Deri Date: Mon, 27 Feb 2023 12:20:15 +0100 Subject: in case of failure, failing result files are not listed --- tests/do.sh.in | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) 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 -- cgit v1.2.3