[rtems-tools commit] tester: Limit branch coverage percentage precision

Joel Sherrill joel at rtems.org
Tue Mar 30 18:20:47 UTC 2021


Module:    rtems-tools
Branch:    master
Commit:    57e7b22fafd795bfc3bc6995bc9692e9711c9782
Changeset: http://git.rtems.org/rtems-tools/commit/?id=57e7b22fafd795bfc3bc6995bc9692e9711c9782

Author:    Alex White <alex.white at oarcorp.com>
Date:      Mon Mar  8 21:58:45 2021 -0600

tester: Limit branch coverage percentage precision

---

 tester/rt/coverage.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tester/rt/coverage.py b/tester/rt/coverage.py
index d88fe04..29ed60b 100644
--- a/tester/rt/coverage.py
+++ b/tester/rt/coverage.py
@@ -181,7 +181,7 @@ class report_gen_html:
                     + '" max="100"></progress></td>' + os.linesep
             row += ' <td>' + summary.branches_uncovered + '</td>' + os.linesep
             row += ' <td>' + summary.branches_total + '</td>' + os.linesep
-            row += ' <td> {:.3%} </td>'.format(summary.percentage_branches_covered)
+            row += ' <td> {:.2%} </td>'.format(summary.percentage_branches_covered)
             spbc = 100 * summary.percentage_branches_covered
             row += ' <td><progress value="{:.3}" max="100"></progress></td>'.format(spbc)
             row += '</tr>' + os.linesep



More information about the vc mailing list