Reports count test.fail() the way Playwright does
A test marked test.fail() that fails is a pass to Playwright, but the report and the terminal summary showed it as a red failure, and showed one that unexpectedly passed as green. They now agree with Playwright.
- An expected failure reads as a pass, with an "expected to fail" badge. Its error is still shown, under "Expected failure".
- A
test.fail()that passed is a failure that reads "Expected to fail, but passed." - The counts explain themselves. The verdict band and the terminal summary add a line such as "1 failed as expected (test.fail)", so it's clear why their counts differ from
report.json.summary.json,report.jsonand what's uploaded to the cloud count exactly as before. - A missing baseline shows up in the report. With
updateSnapshots: 'none', the mode most CI runs use, a comparison whose baseline doesn't exist failed the test but didn't appear in the report, so you couldn't see which snapshot was missing. It's now listed by name, with its verdict. - No more boxes around nothing. The report no longer draws a highlight for an element with no width or height, matching the cloud and Studio.
Released as @testrelic/playwright-analytics 2.16.3 and 2.16.4, on @testrelic/core 2.9.3. Report schema moves to 1.9.0: the streaming report's index rows and per-test meta.json now carry expectedStatus whenever it isn't 'passed'. The addition is optional.