| Index: third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp
|
| diff --git a/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp b/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp
|
| index 969f3fae941b8ad778fbd4e7a8259c33cd639288..10952bab3ae53cfdca33cc675723a82626873dbc 100644
|
| --- a/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp
|
| +++ b/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp
|
| @@ -3156,4 +3156,31 @@ TEST_P(PaintPropertyTreeBuilderTest, TransformOriginWithAndWithoutMotionPath) {
|
| willChange->paintProperties()->transform()->origin());
|
| }
|
|
|
| +TEST_P(PaintPropertyTreeBuilderTest, ChangePositionUpdateDescendantProperties) {
|
| + setBodyInnerHTML(
|
| + "<style>"
|
| + " * { margin: 0; }"
|
| + " #ancestor { position: absolute; overflow: hidden }"
|
| + " #descendant { position: absolute }"
|
| + "</style>"
|
| + "<div id='ancestor'>"
|
| + " <div id='descendant'></div>"
|
| + "</div>");
|
| +
|
| + LayoutObject* ancestor = getLayoutObjectByElementId("ancestor");
|
| + LayoutObject* descendant = getLayoutObjectByElementId("descendant");
|
| + EXPECT_EQ(ancestor->paintProperties()->overflowClip(),
|
| + descendant->paintProperties()
|
| + ->localBorderBoxProperties()
|
| + ->propertyTreeState.clip());
|
| +
|
| + toElement(ancestor->node())
|
| + ->setAttribute(HTMLNames::styleAttr, "position: static");
|
| + document().view()->updateAllLifecyclePhases();
|
| + EXPECT_NE(ancestor->paintProperties()->overflowClip(),
|
| + descendant->paintProperties()
|
| + ->localBorderBoxProperties()
|
| + ->propertyTreeState.clip());
|
| +}
|
| +
|
| } // namespace blink
|
|
|