Skip to content

Commit f1a4f2f

Browse files
Parse/fail percentages now have precision of 2 dp
1 parent 4e6ee78 commit f1a4f2f

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

run-test.bash

+5-2
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,13 @@ failed=`cat $out | grep "|FAIL" | wc -l`
3333
total=`cat $out | wc -l`
3434

3535
echo "Parsed:"
36-
echo $parsed "("$((parsed*100/total))"%) - ("$((parsed_unambig*100/parsed))"% unambiguous)"
36+
parsed_pc=`echo "scale=2;${parsed}*100/${total}" | bc -l`
37+
unambig_pc=`echo "scale=2;${parsed_unambig}*100/${parsed}" | bc -l`
38+
echo "${parsed} (${parsed_pc}%) - (${unambig_pc}% unambiguous)"
3739

3840
echo "NOT parsed:"
39-
echo $failed "("$((failed*100/total))"%)"
41+
failed_pc=`echo "scale=2;${failed}*100/${total}" | bc -l`
42+
echo "${failed} (${failed_pc}%)"
4043

4144
echo "Creating ${out_fail}"
4245
cat $out | grep "|FAIL" | sed "s/^.*|FAIL //" | sort | uniq -c | sort -nr > ${out_fail}

0 commit comments

Comments
 (0)