web-platform-tests / wpt

Test suites for Web platform specs — including WHATWG, W3C, and others
https://web-platform-tests.org/
Other
5.02k stars 3.12k forks source link

[css-pseudo] Fix marker-text-combine-upright.html #49316

Closed chromium-wpt-export-bot closed 21 hours ago

chromium-wpt-export-bot commented 22 hours ago

This test was failing for 2 reasons:

  1. ::marker had text-align: start and text-align-last: start as important UA rules, while the style adjuster only enforces text-align: center in the presence of text-combine-upright: all. This resulted in text-align: center; text-align-last: start.

    Arguably the style adjuster should also set text-align-last, but a smaller fix is changing the important UA rule for ::marker to text-align-last: auto. Note text-align-last: auto behaves as text-align-last: start when text-align: start, so the change has no effect in the great majority of cases.

  2. The style adjuster enforces white-space: pre on outside markers, even if the test uses all: unset.

    So this changes the test reference to expect white-space: pre, and explicitly sets white-space: pre in the test for Firefox.

Bug: 1060007

TEST=external/wpt/css/css-pseudo/marker-text-combine-upright.html

Change-Id: I06e6ac4034abadf956b9d7194b945c9a2c338542 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6021669 Commit-Queue: Oriol Brufau \obrufau@igalia.com Reviewed-by: Rune Lillesveen \futhark@chromium.org Cr-Commit-Position: refs/heads/main@{#1386262}