Part of #2671.
Problem
IssuesReporter.onTestEnd (docs-tests/reporters/issues-reporter.ts:59) pushes every test attempt into collected. With retries: 1 set for CI in playwright.config.ts, a failing assertion is recorded twice — so summary.failed, summary.total and the issues[] array all double, and every row appears twice in the auto-filed drift issue.
Evidence
#2908 was filed as "28 failing assertions (50/90 passed, 12 skipped)" and its table listed all 14 assertions twice.
The real numbers were 14 failures out of 76. Running the same suite locally with retries: 0 produced exactly 14 failures / 24 passed on the integrity project.
The total inflates the same way: 76 real results + 14 retried failures = the 90 reported.
Fix
Keep only the final attempt per TestCase before computing the summary and building issues[] — e.g. key collected by test ID and overwrite, so a retry replaces rather than appends.
Impact
Cosmetic but misleading. Drift issues read as roughly twice as severe as they are, and duplicate rows make triage slower. It also means a flaky-then-passing test could still be counted, since only failed attempts get collected while the eventual pass is recorded separately.
Part of #2671.
Problem
IssuesReporter.onTestEnd(docs-tests/reporters/issues-reporter.ts:59) pushes every test attempt intocollected. Withretries: 1set for CI inplaywright.config.ts, a failing assertion is recorded twice — sosummary.failed,summary.totaland theissues[]array all double, and every row appears twice in the auto-filed drift issue.Evidence
#2908 was filed as "28 failing assertions (50/90 passed, 12 skipped)" and its table listed all 14 assertions twice.
The real numbers were 14 failures out of 76. Running the same suite locally with
retries: 0produced exactly 14 failures / 24 passed on theintegrityproject.The
totalinflates the same way: 76 real results + 14 retried failures = the 90 reported.Fix
Keep only the final attempt per
TestCasebefore computing the summary and buildingissues[]— e.g. keycollectedby test ID and overwrite, so a retry replaces rather than appends.Impact
Cosmetic but misleading. Drift issues read as roughly twice as severe as they are, and duplicate rows make triage slower. It also means a flaky-then-passing test could still be counted, since only failed attempts get collected while the eventual pass is recorded separately.