Index: third_party/WebKit/Source/core/editing/VisibleSelectionTest.cpp |
diff --git a/third_party/WebKit/Source/core/editing/VisibleSelectionTest.cpp b/third_party/WebKit/Source/core/editing/VisibleSelectionTest.cpp |
index b7b041535dd8116f787aab960ee6dc15f520fb37..0b2fe466b9269423061422419cbc6a2e733475ee 100644 |
--- a/third_party/WebKit/Source/core/editing/VisibleSelectionTest.cpp |
+++ b/third_party/WebKit/Source/core/editing/VisibleSelectionTest.cpp |
@@ -479,7 +479,7 @@ TEST_F(VisibleSelectionTest, updateIfNeededWithShadowHost) { |
document().updateStyleAndLayout(); |
// Simulates to restore selection from undo stack. |
- selection.updateIfNeeded(); |
+ selection = createVisibleSelection(selection.asSelection()); |
EXPECT_EQ(Position(sample->firstChild(), 0), selection.start()); |
} |