Closed Bug 1842671 Opened 3 years ago Closed 3 years ago

[wpt-sync] Sync PR 40953 - Rework skew-test1.html to have more reliable expectations.

Categories

(Core :: Web Painting, task, P4)

task

Tracking

()

RESOLVED INVALID

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 40953 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/40953
Details from upstream follow.

Daniel Holbert <dholbert@cs.stanford.edu> wrote:

Rework skew-test1.html to have more reliable expectations.

The old version of this test produced a polygon without precisely-representable vertices, which turned out to be problematic. The reference case might have been correct, but all browsers still had fuzzy-failures, and at least two engines (WebKit and Gecko) had fuzzy-failures with nearly 1000 pixels differing by essentially arbitrarily-large amounts in any color channel.

This reworked version of the test uses multiples of 45deg for the skew angles, which produces a diamond shape whose bounding-box is exactly 2x the width of the original square. This exactness makes the test's expectations easier to reason about and validate.

This reworked version of the test also uses the common "covered-up-target" test approach, to ensure that the transformed shape is the correct size, shape, and position, without suffering from fuzzy-failures that arise from antialiasing or pixel-snapping variability.

This implements my proposal in
https://github.com/web-platform-tests/interop/issues/378

Component: web-platform-tests → Web Painting
Product: Testing → Core
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.