Index: third_party/WebKit/Source/web/tests/NGInlineLayoutTest.cpp |
diff --git a/third_party/WebKit/Source/web/tests/NGInlineLayoutTest.cpp b/third_party/WebKit/Source/web/tests/NGInlineLayoutTest.cpp |
index 8e6a9c346a822b3d0353ae22ef0368ae51c2be92..09328bf137ee3b096ca8d3e895c403f6eebb326f 100644 |
--- a/third_party/WebKit/Source/web/tests/NGInlineLayoutTest.cpp |
+++ b/third_party/WebKit/Source/web/tests/NGInlineLayoutTest.cpp |
@@ -20,7 +20,8 @@ namespace blink { |
class NGInlineLayoutTest : public SimTest { |
public: |
- NGConstraintSpace* constraintSpaceForElement(LayoutNGBlockFlow* blockFlow) { |
+ RefPtr<NGConstraintSpace> constraintSpaceForElement( |
+ LayoutNGBlockFlow* blockFlow) { |
return NGConstraintSpaceBuilder( |
FromPlatformWritingMode(blockFlow->style()->getWritingMode())) |
.SetAvailableSize(NGLogicalSize(LayoutUnit(), LayoutUnit())) |
@@ -45,11 +46,12 @@ TEST_F(NGInlineLayoutTest, BlockWithSingleTextNode) { |
Element* target = document().getElementById("target"); |
LayoutNGBlockFlow* blockFlow = toLayoutNGBlockFlow(target->layoutObject()); |
- NGConstraintSpace* constraintSpace = constraintSpaceForElement(blockFlow); |
+ RefPtr<NGConstraintSpace> constraintSpace = |
+ constraintSpaceForElement(blockFlow); |
NGBlockNode* node = new NGBlockNode(blockFlow); |
RefPtr<NGLayoutResult> result = |
- NGBlockLayoutAlgorithm(node, constraintSpace).Layout(); |
+ NGBlockLayoutAlgorithm(node, constraintSpace.get()).Layout(); |
EXPECT_TRUE(result); |
String expectedText("Hello World!"); |
@@ -69,11 +71,12 @@ TEST_F(NGInlineLayoutTest, BlockWithTextAndAtomicInline) { |
Element* target = document().getElementById("target"); |
LayoutNGBlockFlow* blockFlow = toLayoutNGBlockFlow(target->layoutObject()); |
- NGConstraintSpace* constraintSpace = constraintSpaceForElement(blockFlow); |
+ RefPtr<NGConstraintSpace> constraintSpace = |
+ constraintSpaceForElement(blockFlow); |
NGBlockNode* node = new NGBlockNode(blockFlow); |
RefPtr<NGLayoutResult> result = |
- NGBlockLayoutAlgorithm(node, constraintSpace).Layout(); |
+ NGBlockLayoutAlgorithm(node, constraintSpace.get()).Layout(); |
EXPECT_TRUE(result); |
String expectedText("Hello "); |