From 1239a45d2cd8823f6ea1db62d29fa24099763668 Mon Sep 17 00:00:00 2001 From: Xianzhu Wang Date: Fri, 29 May 2020 17:42:41 +0000 Subject: [PATCH] DCHECK and TODO for crbug.com/786475 (Fieldset should not scroll) This makes the failure more explicit, and make the expectation aligned in pre-CompositeAfterPaint and CompositeAfterPaint for external/wpt/html/rendering/non-replaced-elements/the-fieldset-and-legend-elements/fieldset-overflow.html. Previously in CompositeAfterPaint the test triggered a DCHECK that was not obvious of the reason. Bug: 786475 Change-Id: I93c7df7c731b9f87d88d5ad509d2c6a4d4b10755 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2220159 Commit-Queue: Xianzhu Wang Reviewed-by: Morten Stenshorne Cr-Commit-Position: refs/heads/master@{#773249} --- third_party/blink/renderer/core/paint/fieldset_painter.cc | 2 ++ .../blink/renderer/core/paint/ng/ng_fieldset_painter.cc | 2 ++ .../blink/web_tests/FlagExpectations/composite-after-paint | 1 - third_party/blink/web_tests/TestExpectations | 3 ++- 4 files changed, 6 insertions(+), 2 deletions(-) diff --git a/third_party/blink/renderer/core/paint/fieldset_painter.cc b/third_party/blink/renderer/core/paint/fieldset_painter.cc index e9f12e51372b92..c85f6937a0dc92 100644 --- a/third_party/blink/renderer/core/paint/fieldset_painter.cc +++ b/third_party/blink/renderer/core/paint/fieldset_painter.cc @@ -44,6 +44,8 @@ void FieldsetPainter::PaintBoxDecorationBackground( } BoxDecorationData box_decoration_data(paint_info, layout_fieldset_); + // TODO(crbug.com/786475): Fieldset should not scroll. + DCHECK(!box_decoration_data.IsPaintingScrollingBackground()); if (box_decoration_data.ShouldPaint() && !DrawingRecorder::UseCachedDrawingIfPossible( paint_info.context, layout_fieldset_, paint_info.phase)) { diff --git a/third_party/blink/renderer/core/paint/ng/ng_fieldset_painter.cc b/third_party/blink/renderer/core/paint/ng/ng_fieldset_painter.cc index fe8baf7fa64b02..6d94c26b31eb0c 100644 --- a/third_party/blink/renderer/core/paint/ng/ng_fieldset_painter.cc +++ b/third_party/blink/renderer/core/paint/ng/ng_fieldset_painter.cc @@ -42,6 +42,8 @@ void NGFieldsetPainter::PaintFieldsetDecorationBackground( PhysicalRect paint_rect(paint_offset, fieldset_size); const auto& fragment = fieldset_; BoxDecorationData box_decoration_data(paint_info, fragment); + // TODO(crbug.com/786475): Fieldset should not scroll. + DCHECK(!box_decoration_data.IsPaintingScrollingBackground()); if (!box_decoration_data.ShouldPaint()) return; diff --git a/third_party/blink/web_tests/FlagExpectations/composite-after-paint b/third_party/blink/web_tests/FlagExpectations/composite-after-paint index f2214b2fe6cb2e..f75b8d9f3d6f44 100644 --- a/third_party/blink/web_tests/FlagExpectations/composite-after-paint +++ b/third_party/blink/web_tests/FlagExpectations/composite-after-paint @@ -95,5 +95,4 @@ compositing/gestures/gesture-tapHighlight-composited-img.html [ Pass Failure ] http/tests/images/image-decode-in-frame.html [ Pass Failure ] # Failures after crrev.com/c/2212813 -external/wpt/html/rendering/non-replaced-elements/the-fieldset-and-legend-elements/fieldset-overflow.html [ Crash ] fast/table/cell-percent-padding.html [ Crash ] diff --git a/third_party/blink/web_tests/TestExpectations b/third_party/blink/web_tests/TestExpectations index f0da3db31a1c5c..f0416c65e1010b 100644 --- a/third_party/blink/web_tests/TestExpectations +++ b/third_party/blink/web_tests/TestExpectations @@ -735,6 +735,8 @@ crbug.com/1068947 [ Win10 ] external/wpt/css/css-text-decor/text-underline-posit # Tentative mansonry tests crbug.com/1076027 external/wpt/css/css-grid/masonry.tentative/* [ Skip ] +crbug.com/786475 external/wpt/html/rendering/non-replaced-elements/the-fieldset-and-legend-elements/fieldset-overflow.html [ Failure Crash ] + # ====== Layout team owned tests to here ====== # ====== LayoutNG-only failures from here ====== @@ -3197,7 +3199,6 @@ crbug.com/432153 external/wpt/css/css-masking/mask-image/mask-image-url-local-ma crbug.com/432153 external/wpt/css/css-masking/mask-image/mask-image-url-image.html [ Failure ] crbug.com/432153 external/wpt/css/css-masking/mask-image/mask-image-url-remote-mask.html [ Failure ] crbug.com/432153 external/wpt/css/css-masking/mask-image/mask-image-url-image-hash.html [ Failure ] -crbug.com/626703 external/wpt/html/rendering/non-replaced-elements/the-fieldset-and-legend-elements/fieldset-overflow.html [ Failure ] crbug.com/626703 external/wpt/css/CSS2/floats/float-nowrap-9.html [ Failure ] crbug.com/626703 external/wpt/css/CSS2/floats/float-nowrap-8.html [ Failure ] crbug.com/626703 external/wpt/css/CSS2/floats/float-nowrap-7.html [ Failure ]