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

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

Issue 1710083005: Remove old downloads UI; Material Design version is now the default. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove testing/ Created 4 years, 10 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
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 <stddef.h> 5 #include <stddef.h>
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/files/file_util.h" 8 #include "base/files/file_util.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 const int kMoveIterations = 30; 80 const int kMoveIterations = 30;
81 81
82 } // namespace 82 } // namespace
83 83
84 class FindInPageControllerTest : public InProcessBrowserTest { 84 class FindInPageControllerTest : public InProcessBrowserTest {
85 public: 85 public:
86 FindInPageControllerTest() { 86 FindInPageControllerTest() {
87 chrome::DisableFindBarAnimationsDuringTesting(true); 87 chrome::DisableFindBarAnimationsDuringTesting(true);
88 } 88 }
89 89
90 // Disable new downloads UI as it is very very slow. https://crbug.com/526577
91 // TODO(dbeam): remove this once the downloads UI is not slow.
92 void SetUpCommandLine(base::CommandLine* command_line) override {
93 InProcessBrowserTest::SetUpCommandLine(command_line);
94 command_line->AppendSwitch(switches::kDisableMaterialDesignDownloads);
95 }
96
97 protected: 90 protected:
98 bool GetFindBarWindowInfoForBrowser( 91 bool GetFindBarWindowInfoForBrowser(
99 Browser* browser, gfx::Point* position, bool* fully_visible) { 92 Browser* browser, gfx::Point* position, bool* fully_visible) {
100 FindBarTesting* find_bar = 93 FindBarTesting* find_bar =
101 browser->GetFindBarController()->find_bar()->GetFindBarTesting(); 94 browser->GetFindBarController()->find_bar()->GetFindBarTesting();
102 return find_bar->GetFindBarWindowInfo(position, fully_visible); 95 return find_bar->GetFindBarWindowInfo(position, fully_visible);
103 } 96 }
104 97
105 bool GetFindBarWindowInfo(gfx::Point* position, bool* fully_visible) { 98 bool GetFindBarWindowInfo(gfx::Point* position, bool* fully_visible) {
106 return GetFindBarWindowInfoForBrowser(browser(), position, fully_visible); 99 return GetFindBarWindowInfoForBrowser(browser(), position, fully_visible);
(...skipping 1446 matching lines...) Expand 10 before | Expand all | Expand 10 after
1553 1546
1554 EXPECT_TRUE(chrome::ExecuteCommand(browser_incognito, IDC_FIND_NEXT)); 1547 EXPECT_TRUE(chrome::ExecuteCommand(browser_incognito, IDC_FIND_NEXT));
1555 WebContents* web_contents_incognito = 1548 WebContents* web_contents_incognito =
1556 browser_incognito->tab_strip_model()->GetActiveWebContents(); 1549 browser_incognito->tab_strip_model()->GetActiveWebContents();
1557 ui_test_utils::FindInPageNotificationObserver observer( 1550 ui_test_utils::FindInPageNotificationObserver observer(
1558 web_contents_incognito); 1551 web_contents_incognito);
1559 observer.Wait(); 1552 observer.Wait();
1560 EXPECT_EQ(ASCIIToUTF16("bar"), 1553 EXPECT_EQ(ASCIIToUTF16("bar"),
1561 GetFindBarTextForBrowser(browser_incognito)); 1554 GetFindBarTextForBrowser(browser_incognito));
1562 } 1555 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/browser_navigator_browsertest.cc ('k') | chrome/browser/ui/webui/chrome_web_ui_controller_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698