Commit 21e34f1c authored by mpearson's avatar mpearson Committed by Commit bot

Make OmniboxViewTest.BasicTextOperations Work on Linux

BUG=408637

Review URL: https://codereview.chromium.org/561983002

Cr-Commit-Position: refs/heads/master@{#295168}
parent ae43e039
......@@ -742,8 +742,7 @@ IN_PROC_BROWSER_TEST_F(OmniboxViewTest, EscapeToDefaultMatch) {
}
// Flaky on Windows: http://crbug.com/146619
// Fails on Linux: http://crbug.com/408637
#if defined(OS_WIN) || defined(OS_LINUX)
#if defined(OS_WIN)
#define MAYBE_BasicTextOperations DISABLED_BasicTextOperations
#else
#define MAYBE_BasicTextOperations BasicTextOperations
......@@ -762,6 +761,10 @@ IN_PROC_BROWSER_TEST_F(OmniboxViewTest, MAYBE_BasicTextOperations) {
size_t start, end;
omnibox_view->GetSelectionBounds(&start, &end);
#if defined(OS_WIN) || defined(OS_LINUX)
// Views textfields select-all in reverse to show the leading text.
std::swap(start, end);
#endif
EXPECT_EQ(0U, start);
EXPECT_EQ(old_text.size(), end);
......@@ -792,6 +795,10 @@ IN_PROC_BROWSER_TEST_F(OmniboxViewTest, MAYBE_BasicTextOperations) {
omnibox_view->SelectAll(true);
EXPECT_TRUE(omnibox_view->IsSelectAll());
omnibox_view->GetSelectionBounds(&start, &end);
#if defined(OS_WIN) || defined(OS_LINUX)
// Views textfields select-all in reverse to show the leading text.
std::swap(start, end);
#endif
EXPECT_EQ(0U, start);
EXPECT_EQ(old_text.size(), end);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment