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

Unified Diff: third_party/WebKit/Source/web/tests/WebFrameTest.cpp

Issue 1958093002: CONTINUED Make FrameSelection to hold non-canonicalized positions Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 2017-01-16T20:04:35 Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/core/page/FocusController.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/web/tests/WebFrameTest.cpp
diff --git a/third_party/WebKit/Source/web/tests/WebFrameTest.cpp b/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
index 6665c81433a7b79058b8098df9f03ccd67356ced..698572c6d34db46e61384cb17cb0a07540fb073c 100644
--- a/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
+++ b/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
@@ -5119,7 +5119,9 @@ TEST_P(ParameterizedWebFrameTest, SelectRange) {
initializeTextSelectionWebView(m_baseURL + "select_range_basic.html",
&webViewHelper);
frame = webViewHelper.webView()->mainFrameImpl();
- EXPECT_EQ("Some test text for testing.", selectionAsString(frame));
+ // TODO(yosin): Since selection is canonicalized with size(0, 0) window,
+ // we should hold original range.
+ EXPECT_EQ(" Some test text for testing.", selectionAsString(frame));
webViewHelper.webView()->selectionBounds(startWebRect, endWebRect);
frame->executeCommand(WebString::fromUTF8("Unselect"));
EXPECT_EQ("", selectionAsString(frame));
@@ -5127,8 +5129,8 @@ TEST_P(ParameterizedWebFrameTest, SelectRange) {
// On some devices, the above bottomRightMinusOne() causes the ending '.' not
// selected.
std::string selectionString = selectionAsString(frame);
- EXPECT_TRUE(selectionString == "Some test text for testing." ||
- selectionString == "Some test text for testing");
+ EXPECT_TRUE(selectionString == " Some test text for testing." ||
+ selectionString == " Some test text for testing");
initializeTextSelectionWebView(m_baseURL + "select_range_scroll.html",
&webViewHelper);
« no previous file with comments | « third_party/WebKit/Source/core/page/FocusController.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698