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

Side by Side Diff: chrome/browser/ui/find_bar/find_bar_host_browsertest.cc

Issue 254983005: [Sheriff] Disable FindRestarts_Issue70505 for being flaky. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "base/file_util.h" 5 #include "base/file_util.h"
6 #include "base/message_loop/message_loop.h" 6 #include "base/message_loop/message_loop.h"
7 #include "base/prefs/pref_service.h" 7 #include "base/prefs/pref_service.h"
8 #include "base/strings/string16.h" 8 #include "base/strings/string16.h"
9 #include "base/strings/string_util.h" 9 #include "base/strings/string_util.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 779 matching lines...) Expand 10 before | Expand all | Expand 10 after
790 // This string appears 5 times at the bottom of a long page. If Find restarts 790 // This string appears 5 times at the bottom of a long page. If Find restarts
791 // properly after a timeout, it will find 5 matches, not just 1. 791 // properly after a timeout, it will find 5 matches, not just 1.
792 int ordinal = 0; 792 int ordinal = 0;
793 EXPECT_EQ(5, FindInPageWchar(browser()->tab_strip_model()-> 793 EXPECT_EQ(5, FindInPageWchar(browser()->tab_strip_model()->
794 GetActiveWebContents(), 794 GetActiveWebContents(),
795 L"008.xml", 795 L"008.xml",
796 kFwd, kIgnoreCase, &ordinal)); 796 kFwd, kIgnoreCase, &ordinal));
797 EXPECT_EQ(1, ordinal); 797 EXPECT_EQ(1, ordinal);
798 } 798 }
799 799
800 // Disable the test for win and mac as it started being flaky, see
801 // http://crbug/367701.
802 #if defined(OS_MACOSX) && !defined(OS_IOS) || defined(OS_WIN)
803 #define MAYBE_FindRestarts_Issue70505 DISABLED_FindRestarts_Issue70505
804 #else
805 #define MAYBE_FindRestarts_Issue70505 FindRestarts_Issue70505
806 #endif
800 // Make sure we don't get into an infinite loop when text box contains very 807 // Make sure we don't get into an infinite loop when text box contains very
801 // large amount of text. 808 // large amount of text.
802 IN_PROC_BROWSER_TEST_F(FindInPageControllerTest, FindRestarts_Issue70505) { 809 IN_PROC_BROWSER_TEST_F(FindInPageControllerTest,
810 MAYBE_FindRestarts_Issue70505) {
803 // First we navigate to our page. 811 // First we navigate to our page.
804 GURL url = GetURL(kLongTextareaPage); 812 GURL url = GetURL(kLongTextareaPage);
805 ui_test_utils::NavigateToURL(browser(), url); 813 ui_test_utils::NavigateToURL(browser(), url);
806 814
807 // If this test hangs on the FindInPage call, then it might be a regression 815 // If this test hangs on the FindInPage call, then it might be a regression
808 // such as the one found in issue http://crbug.com/70505. 816 // such as the one found in issue http://crbug.com/70505.
809 int ordinal = 0; 817 int ordinal = 0;
810 FindInPageWchar(browser()->tab_strip_model()->GetActiveWebContents(), 818 FindInPageWchar(browser()->tab_strip_model()->GetActiveWebContents(),
811 L"a", kFwd, kIgnoreCase, &ordinal); 819 L"a", kFwd, kIgnoreCase, &ordinal);
812 EXPECT_EQ(1, ordinal); 820 EXPECT_EQ(1, ordinal);
(...skipping 804 matching lines...) Expand 10 before | Expand all | Expand 10 after
1617 ASSERT_EQ(result, SIMPLEREGION); 1625 ASSERT_EQ(result, SIMPLEREGION);
1618 bool rects_equal = 1626 bool rects_equal =
1619 region_before.left == region_after.left && 1627 region_before.left == region_after.left &&
1620 region_before.top == region_after.top && 1628 region_before.top == region_after.top &&
1621 region_before.right == region_after.right && 1629 region_before.right == region_after.right &&
1622 region_before.bottom == region_after.bottom; 1630 region_before.bottom == region_after.bottom;
1623 ASSERT_FALSE(rects_equal); 1631 ASSERT_FALSE(rects_equal);
1624 } 1632 }
1625 1633
1626 #endif 1634 #endif
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698