]> The Tcpdump Group git mirrors - tcpdump/blobdiff - tests/lmp-v.sh
Count the complex tests correctly, and pick up the counts correctly.
[tcpdump] / tests / lmp-v.sh
index 2d0188642910c617f912069622cbb46a19327227..a8c6740e500f2d0cc6c0447f01a56fa77fa27de2 100755 (executable)
@@ -15,8 +15,17 @@ then
        printf '    %-35s: TEST SKIPPED (no Makefile)\n' 'lmp-v'
 elif grep '^CC = .*gcc' ../Makefile >/dev/null
 then
-       ./TESTonce lmp-v lmp.pcap lmp-v.out '-T lmp -v'
-       [ $? -eq 0 ] || exitcode=1
+       passed=`cat .passed`
+       failed=`cat .failed`
+       if ./TESTonce lmp-v lmp.pcap lmp-v.out '-T lmp -v'
+       then
+               passed=`expr $passed + 1`
+               echo $passed >.passed
+       else
+               failed=`expr $failed + 1`
+               echo $failed >.failed
+               exitcode=1
+       fi
 else
        printf '    %-35s: TEST SKIPPED (compiler is not GCC)\n' 'lmp-v'
 fi