Skip to content
Permalink
Browse files
Update css3/flexbox/auto-margins.html after r177774
https://bugs.webkit.org/show_bug.cgi?id=139975

Patch by Myles C. Maxfield <litherum@gmail.com> on 2015-01-07
Reviewed by Darin Adler.

This is a subpixel problem. Flexbox uses SimpleLineLayout for the entire
box and therefore does all its math in floating point, while the
-expected uses the regular renderer hierarchy and therefore fixed-point
math. This patch updates the test to use Ahem so that the character
widths divide the same way in both cases.

* css3/flexbox/auto-margins-expected.html:
* css3/flexbox/auto-margins.html:
* platform/mac/TestExpectations:

Canonical link: https://commits.webkit.org/158177@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@178063 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
litherum committed Jan 7, 2015
1 parent c0b0f41 commit 53afe75d6cb4275050caf792e9cbb672913b556d
Showing with 23 additions and 7 deletions.
  1. +17 −0 LayoutTests/ChangeLog
  2. +3 −3 LayoutTests/css3/flexbox/auto-margins-expected.html
  3. +3 −3 LayoutTests/css3/flexbox/auto-margins.html
  4. +0 −1 LayoutTests/platform/mac/TestExpectations
@@ -1,3 +1,20 @@
2015-01-07 Myles C. Maxfield <litherum@gmail.com>

Update css3/flexbox/auto-margins.html after r177774
https://bugs.webkit.org/show_bug.cgi?id=139975

Reviewed by Darin Adler.

This is a subpixel problem. Flexbox uses SimpleLineLayout for the entire
box and therefore does all its math in floating point, while the
-expected uses the regular renderer hierarchy and therefore fixed-point
math. This patch updates the test to use Ahem so that the character
widths divide the same way in both cases.

* css3/flexbox/auto-margins-expected.html:
* css3/flexbox/auto-margins.html:
* platform/mac/TestExpectations:

2015-01-07 Brent Fulgham <bfulgham@apple.com>

[Win] Unreviewed test gardening (writing-mode).
@@ -16,13 +16,13 @@
<body>
<p>These tests are from the spec: <a href="http://dev.w3.org/csswg/css3-flexbox/#auto-margins">http://dev.w3.org/csswg/css3-flexbox/#auto-margins</a>.</p>

<p>The word OK should be centered vertically and horizontally.</p>
<p>A black box should be centered vertically and horizontally.</p>
<div style="width: 4em; height: 4em; background: silver">
<table style="width: 100%; height: 100%;"><tr><td style="text-align: center">OK</td></tr></table>
<table style="width: 100%; height: 100%;"><tr><td style="text-align: center; font-family: Ahem;">OK</td></tr></table>
</div>

<div style="width: 4em; height: 4em; margin-top: 10px; background: silver; -webkit-writing-mode: vertical-rl">
<table style="width: 100%; height: 100%;"><tr><td style="text-align: center">OK</td></tr></table>
<table style="width: 100%; height: 100%;"><tr><td style="text-align: center; font-family: Ahem;">OK</td></tr></table>
</div>

<p>You should see 3 blue concentric circles.</p>
@@ -23,13 +23,13 @@
<body>
<p>These tests are from the spec: <a href="http://dev.w3.org/csswg/css3-flexbox/#auto-margins">http://dev.w3.org/csswg/css3-flexbox/#auto-margins</a>.</p>

<p>The word OK should be centered vertically and horizontally.</p>
<p>A black box should be centered vertically and horizontally.</p>
<div class="flexbox" style="width: 4em; height: 4em; background: silver">
<p id="ok" style="margin: auto;">OK</p>
<p id="ok" style="margin: auto; font-family: Ahem;">OK</p>
</div>

<div class="flexbox" style="width: 4em; height: 4em; margin-top: 10px; background: silver; -webkit-writing-mode: vertical-rl">
<p id="okVertical" style="margin: auto;">OK</p>
<p id="okVertical" style="margin: auto; font-family: Ahem;">OK</p>
</div>

<p>You should see 3 blue concentric circles.</p>
@@ -1339,7 +1339,6 @@ fast/canvas/canvas-fillRect-gradient-shadow.html [ Pass Failure ]

# Kerning, Ligatures, and Printer Fonts caused these tests to fail
# The following tests are reftests
webkit.org/b/139968 css3/flexbox/auto-margins.html [ ImageOnlyFailure ]
webkit.org/b/139968 css3/flexbox/csswg/flexbox_direction-row-reverse.html [ ImageOnlyFailure ]
webkit.org/b/139968 fast/box-decoration-break/box-decoration-break-rendering.html [ ImageOnlyFailure ]
webkit.org/b/139968 fast/css-generated-content/after-with-inline-continuation.html [ ImageOnlyFailure ]

0 comments on commit 53afe75

Please sign in to comment.