REGTESTS: fix error when no test are skipped

Since commit 1ed2c9d ("REGTESTS: list all skipped tests including
'feature cmd' ones"), the script emits some error when trying to display
the list of skipped tests when there are none.

No backport needed.
This commit is contained in:
William Lallemand 2025-12-18 17:23:23 +01:00
parent 9a046fc3ad
commit 876b1e8477

View file

@ -427,11 +427,13 @@ $(grep -E -- "^(----|\* diag)" "$i/LOG")
EOF
done' sh {} +
fi
echo "########################## Listing skipped tests ####################"
count=$(wc -l < "${TESTDIR}/skipped.log")
cat "${TESTDIR}/skipped.log" | sort -n
echo "Total skipped tests: $count"
echo "########################## Listing skipped tests ####################"
count=0
if [ -e "${TESTDIR}/skipped.log" ]; then
count=$(wc -l < "${TESTDIR}/skipped.log")
cat "${TESTDIR}/skipped.log" | sort -n
fi
echo "Total skipped tests: $count"
fi # if TESTDIR