From f8314e3336ca530ac7bb0857b3143922a869aeaf Mon Sep 17 00:00:00 2001 From: hathach Date: Wed, 24 Jun 2026 15:44:26 +0700 Subject: [PATCH] test/hil: show pass/fail/skip counts above the HIL report table Prefix each rig's hil_report.md matrix with a one-line tally (passed / failed / skipped) so the number of failed tests is visible at a glance in the PR comment without scanning the table. A metric-string cell (e.g. throughput) counts as a pass; blank/not-run cells are excluded. Co-Authored-By: Claude Opus 4.8 (1M context) --- test/hil/hil_test.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/test/hil/hil_test.py b/test/hil/hil_test.py index 07375c1ad..e66c86e56 100755 --- a/test/hil/hil_test.py +++ b/test/hil/hil_test.py @@ -1756,8 +1756,14 @@ def render_matrix(rows_all: list) -> str: sep = '| ' + '-' * board_w + ' | ' + ' | '.join(':' + '-' * (w - 2) + ':' for w in col_w) + ' |' body = [line(lbl, [cell(cells, c) for c in columns]) for lbl, cells in rows_all] - legend = 'Legend: ✅ pass · ❌ fail · ⚪ skipped · blank not run' - return '\n'.join([header, sep] + body) + '\n\n' + legend + # tally run cells (blank/not-run cells are absent from the dicts); a metric string counts as pass + failed = sum(v == 'fail' for _, cells in rows_all for v in cells.values()) + skipped = sum(v == 'skip' for _, cells in rows_all for v in cells.values()) + passed = sum(v not in ('fail', 'skip') for _, cells in rows_all for v in cells.values()) + summary = (f'**{REPORT_CELL["pass"]} {passed} passed · {REPORT_CELL["fail"]} {failed} failed · ' + f'{REPORT_CELL["skip"]} {skipped} skipped · blank not run**') + + return summary + '\n\n' + '\n'.join([header, sep] + body) def accumulate_report(mret: list, report_dir: Path, fresh: bool) -> str: