Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(637)

Side by Side Diff: third_party/WebKit/Source/core/dom/TextTest.cpp

Issue 1686483002: Oilpan: Remove most WillBe types from the code base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Source/core/dom/Text.cpp ('k') | third_party/WebKit/Source/core/dom/Touch.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2016 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "core/dom/Text.h" 5 #include "core/dom/Text.h"
6 6
7 #include "core/dom/Range.h" 7 #include "core/dom/Range.h"
8 #include "core/editing/EditingTestBase.h" 8 #include "core/editing/EditingTestBase.h"
9 #include "core/html/HTMLPreElement.h" 9 #include "core/html/HTMLPreElement.h"
10 #include "core/layout/LayoutText.h" 10 #include "core/layout/LayoutText.h"
11 11
12 namespace blink { 12 namespace blink {
13 13
14 // TODO(xiaochengh): Use a new testing base class. 14 // TODO(xiaochengh): Use a new testing base class.
15 class TextTest : public EditingTestBase { 15 class TextTest : public EditingTestBase {
16 }; 16 };
17 17
18 TEST_F(TextTest, RemoveFirstLetterPseudoElementWhenNoLetter) 18 TEST_F(TextTest, RemoveFirstLetterPseudoElementWhenNoLetter)
19 { 19 {
20 document().documentElement()->setInnerHTML("<style>*::first-letter{font:icon ;}</style><pre>AB\n</pre>", ASSERT_NO_EXCEPTION); 20 document().documentElement()->setInnerHTML("<style>*::first-letter{font:icon ;}</style><pre>AB\n</pre>", ASSERT_NO_EXCEPTION);
21 updateLayoutAndStyleForPainting(); 21 updateLayoutAndStyleForPainting();
22 22
23 RefPtrWillBeRawPtr<Element> pre = document().querySelector("pre", ASSERT_NO_ EXCEPTION); 23 RawPtr<Element> pre = document().querySelector("pre", ASSERT_NO_EXCEPTION);
24 Text* text = toText(pre->firstChild()); 24 Text* text = toText(pre->firstChild());
25 25
26 RefPtrWillBeRawPtr<Range> range = Range::create(document(), text, 0, text, 2 ); 26 RawPtr<Range> range = Range::create(document(), text, 0, text, 2);
27 range->deleteContents(ASSERT_NO_EXCEPTION); 27 range->deleteContents(ASSERT_NO_EXCEPTION);
28 updateLayoutAndStyleForPainting(); 28 updateLayoutAndStyleForPainting();
29 29
30 EXPECT_FALSE(text->layoutObject()->isTextFragment()); 30 EXPECT_FALSE(text->layoutObject()->isTextFragment());
31 } 31 }
32 32
33 } // namespace blink 33 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/Text.cpp ('k') | third_party/WebKit/Source/core/dom/Touch.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698