Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: toHaveScreenshot sometimes not showing actual/diff on error for webkit #34565

Open
dimkin-eu opened this issue Jan 31, 2025 · 1 comment

Comments

@dimkin-eu
Copy link

Version

1.50.0

Steps to reproduce

I understand this is a very vague description, but I can't find any consistent pattern.
It happens for 1-2 tests out of 2K+, but this fail the whole job :(
The only idea that comes to my mind - the page wasn't stable to assert a screenshot, but animations are disabled by our code - anyway some actual screenshot must be there

    await expect(page).toHaveScreenshot(`${filename}.png`, {
        scale: "css",
        caret: "hide",
        animations: "allow",
        maxDiffPixels,
    })

Expected behavior

on error 3 images produced

Actual behavior

only expected image in stacktrace/report

    Error: Timed out 15000ms waiting for expect(page).toHaveScreenshot(expected)
      Timeout 15000ms exceeded.
    Expected: /builds/frontend/foobar.png
    Call log:
      - expect.toHaveScreenshot(foobar.png) with timeout 15000ms
        - verifying given screenshot expectation
      - taking page screenshot
      - waiting for fonts to load...
      - fonts loaded
      - Timeout 15000ms exceeded.
     

Additional context

No response

Environment

FROM mcr.microsoft.com/playwright:v1.50.0-jammy
pnpm 9.15.2
@dimkin-eu dimkin-eu changed the title [Bug]: toHaveScreenshot sometimes not showing actial/diff on error for webkit [Bug]: toHaveScreenshot sometimes not showing actual/diff on error for webkit Jan 31, 2025
@agg23
Copy link
Contributor

agg23 commented Jan 31, 2025

Please provide a complete and minimal repro of this issue. Otherwise we cannot diagnose it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants