Skip to content

Commit

Permalink
[css-flex] Change expectations of two aspect-ratio tests
Browse files Browse the repository at this point in the history
New expectations incorporate an item's min-intrinsic size as part of
flex's automatic minimum sizing.

The new expectations are arguably what the spec currently calls for AND
what the spec authors originally intended AND are consistent with both
relevant proposals in w3c/csswg-drafts#6794

Also discussed at
web-platform-tests/interop#139 (comment)

Change-Id: I3c6ecdf66fbb4ee745c88b6b2a4dbecfb9913908
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3924134
Commit-Queue: David Grogan <dgrogan@chromium.org>
Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1052123}
NOKEYCHECK=True
GitOrigin-RevId: cc4f488e5e9e8a496e5135e6d6fcea62eac77088
  • Loading branch information
davidsgrogan authored and copybara-github committed Sep 28, 2022
1 parent 1f4a82e commit 508529b
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 6 deletions.
1 change: 0 additions & 1 deletion blink/web_tests/FlagExpectations/disable-layout-ng
Original file line number Diff line number Diff line change
Expand Up @@ -877,7 +877,6 @@ crbug.com/1045668 external/wpt/css/css-sizing/aspect-ratio/abspos-013.html [ Pas
crbug.com/1154572 external/wpt/css/css-sizing/aspect-ratio/block-aspect-ratio-030.html [ Failure ]
crbug.com/1154572 external/wpt/css/css-sizing/aspect-ratio/block-aspect-ratio-037.html [ Failure ]
crbug.com/1251788 external/wpt/css/css-sizing/aspect-ratio/flex-aspect-ratio-002.html [ Failure ]
crbug.com/1251788 external/wpt/css/css-sizing/aspect-ratio/flex-aspect-ratio-004.html [ Failure ]
crbug.com/1157740 external/wpt/css/css-sizing/aspect-ratio/flex-aspect-ratio-024.html [ Failure ]
crbug.com/1157740 external/wpt/css/css-sizing/aspect-ratio/flex-aspect-ratio-026.html [ Failure ]
crbug.com/1157740 external/wpt/css/css-sizing/aspect-ratio/flex-aspect-ratio-042.html [ Failure ]
Expand Down
2 changes: 1 addition & 1 deletion blink/web_tests/TestExpectations
Original file line number Diff line number Diff line change
Expand Up @@ -998,7 +998,7 @@ crbug.com/711807 external/wpt/css/CSS2/normal-flow/replaced-intrinsic-002.xht [

#### external/wpt/css/css-sizing
crbug.com/1322062 external/wpt/css/css-sizing/aspect-ratio/fieldset-element-001.html [ Failure ]
crbug.com/1261306 external/wpt/css/css-sizing/aspect-ratio/flex-aspect-ratio-004.html [ Failure ]
crbug.com/1281709 external/wpt/css/css-sizing/aspect-ratio/flex-aspect-ratio-002.html [ Failure ]
crbug.com/970201 external/wpt/css/css-sizing/slice-intrinsic-size.html [ Failure ]
crbug.com/970201 external/wpt/css/css-sizing/clone-intrinsic-size.html [ Failure ]
crbug.com/1343829 external/wpt/css/css-sizing/aspect-ratio/block-aspect-ratio-038.html [ Failure ]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@

<div style="display: flex;">
<!-- No transferred size suggestion since the flex item is non-replaced.
Content size suggestion is 50px because 50px is item's min-content size. -->
Content size suggestion is 100px because min-intrinsic width is 100px.
-->
<div style="background: green; height: 100px; aspect-ratio: 1/2; flex-basis: 0;">
<div style="width: 100px;"></div>
</div>
<div style="background: green; height: 100px; width: 50px;"></div>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,9 @@

<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>

<div style="background: green; width: 100px; height:50px;"></div>
<div style="display: flex; flex-direction: column;">
<!-- No transferred size suggestion since the flex item is non-replaced.
Content size suggestion is 50px because min-content size is 50px. -->
Content size suggestion is 100px because min-intrinsic height is 100px. -->
<div style="background: green; width: 100px; aspect-ratio: 2/1; flex-basis: 0;">
<div style="height: 100px;"></div>
</div>
Expand Down

0 comments on commit 508529b

Please sign in to comment.