Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 37ce42c1 authored by David Ahern's avatar David Ahern Committed by David S. Miller
Browse files

selftests: fib_tests: Add success-fail counts



As more tests are added, it is convenient to have a tally at the end.

Signed-off-by: default avatarDavid Ahern <dsahern@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent f34436a4
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -18,8 +18,10 @@ log_test()

	if [ ${rc} -eq ${expected} ]; then
		printf "    TEST: %-60s  [ OK ]\n" "${msg}"
		nsuccess=$((nsuccess+1))
	else
		ret=1
		nfail=$((nfail+1))
		printf "    TEST: %-60s  [FAIL]\n" "${msg}"
		if [ "${PAUSE_ON_FAIL}" = "yes" ]; then
		echo
@@ -598,4 +600,9 @@ cleanup &> /dev/null

fib_test

if [ "$TESTS" != "none" ]; then
	printf "\nTests passed: %3d\n" ${nsuccess}
	printf "Tests failed: %3d\n"   ${nfail}
fi

exit $ret