Skip to content

test: HiDPI viewer window test can read pixels before the expanded repaint #408

Closed

Description

@ElbertePlinio

Problem

crates/pickforge-viewer/tests/window.rs > scales_with_the_host_scale_factor fails intermittently on a local host. It failed 4 of 8 runs on main at d4561b5 with bar color: left: 2382024, right: 986897. The pixel at (8, 8) of the expanded window is the session's blue (0x2458c8), not the bar color (0x0f0f11).

The test waits until the window has the expanded size, then takes the screenshot. The viewer can still show the thumbnail frame at that moment, so the screenshot can precede the expanded repaint. No CI run has shown this failure yet.

Where it was found

While running cargo test --workspace --locked for #374. The failure does not depend on the #374 changes: it also fails with the input.rs from main.

Acceptance criteria

  • The test waits for the expanded frame, not only the expanded size, before it checks pixels.
  • The test passes in a loop under load.

Checklist

  • Wait for the bar color, or for a frame event, before the pixel checks
  • Run the test in a loop pinned to one CPU

Activity

  1. added
    bug
    on Oct 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions