add--interactive: detect bogus diffFilter output
[git/debian.git] / t / aggregate-results.sh
blob7913e206ed6b73d16779e91d6a9197e602626c57
1 #!/bin/sh
3 failed_tests=
4 fixed=0
5 success=0
6 failed=0
7 broken=0
8 total=0
10 while read file
12 while read type value
14 case $type in
15 '')
16 continue ;;
17 fixed)
18 fixed=$(($fixed + $value)) ;;
19 success)
20 success=$(($success + $value)) ;;
21 failed)
22 failed=$(($failed + $value))
23 if test $value != 0
24 then
25 testnum=$(expr "$file" : 'test-results/\(t[0-9]*\)-')
26 failed_tests="$failed_tests $testnum"
29 broken)
30 broken=$(($broken + $value)) ;;
31 total)
32 total=$(($total + $value)) ;;
33 esac
34 done <"$file"
35 done
37 if test -n "$failed_tests"
38 then
39 printf "\nfailed test(s):$failed_tests\n\n"
42 printf "%-8s%d\n" fixed $fixed
43 printf "%-8s%d\n" success $success
44 printf "%-8s%d\n" failed $failed
45 printf "%-8s%d\n" broken $broken
46 printf "%-8s%d\n" total $total