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

Unified Diff: chrome/browser/ui/search/instant_extended_manual_interactive_uitest.cc

Issue 18223002: InstantExtended: Remove overlay control code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Call renamed method. Created 7 years, 6 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
Index: chrome/browser/ui/search/instant_extended_manual_interactive_uitest.cc
diff --git a/chrome/browser/ui/search/instant_extended_manual_interactive_uitest.cc b/chrome/browser/ui/search/instant_extended_manual_interactive_uitest.cc
index 00c701c3f7f4848272011380096b26947ab08a3e..6ee7e9400994cef5234ca5be9ff2d041fc9d0d5d 100644
--- a/chrome/browser/ui/search/instant_extended_manual_interactive_uitest.cc
+++ b/chrome/browser/ui/search/instant_extended_manual_interactive_uitest.cc
@@ -11,7 +11,6 @@
#include "chrome/browser/ui/host_desktop.h"
#include "chrome/browser/ui/omnibox/omnibox_view.h"
#include "chrome/browser/ui/search/instant_ntp.h"
-#include "chrome/browser/ui/search/instant_overlay.h"
#include "chrome/browser/ui/search/instant_test_utils.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h"
#include "chrome/common/chrome_notification_types.h"
@@ -60,7 +59,7 @@ class InstantExtendedManualTest : public InProcessBrowserTest,
testing::UnitTest::GetInstance()->current_test_info();
ASSERT_TRUE(StartsWithASCII(test_info->name(), "MANUAL_", true) ||
StartsWithASCII(test_info->name(), "DISABLED_", true));
- // Make IsOffline() return false so we don't try to use the local overlay.
+ // Make IsOffline() return false so we don't try to use the local NTP.
disable_network_change_notifier_.reset(
new net::NetworkChangeNotifier::DisableForTest());
}
@@ -78,47 +77,6 @@ class InstantExtendedManualTest : public InProcessBrowserTest,
return browser()->tab_strip_model()->GetActiveWebContents();
}
- bool PressBackspace() {
- return ui_test_utils::SendKeyPressSync(browser(), ui::VKEY_BACK,
- false, false, false, false);
- }
-
- bool PressBackspaceAndWaitForSuggestions() {
- content::WindowedNotificationObserver observer(
- chrome::NOTIFICATION_INSTANT_SET_SUGGESTION,
- content::NotificationService::AllSources());
- bool result = PressBackspace();
- observer.Wait();
- return result;
- }
-
- bool PressBackspaceAndWaitForOverlayToShow() {
- InstantTestModelObserver observer(
- instant()->model(), SearchMode::MODE_SEARCH_SUGGESTIONS);
- return PressBackspace() && observer.WaitForExpectedOverlayState() ==
- SearchMode::MODE_SEARCH_SUGGESTIONS;
- }
-
- bool PressEnterAndWaitForNavigationWithTitle(content::WebContents* contents,
- const string16& title) {
- content::TitleWatcher title_watcher(contents, title);
- content::WindowedNotificationObserver nav_observer(
- content::NOTIFICATION_NAV_ENTRY_COMMITTED,
- content::NotificationService::AllSources());
- browser()->window()->GetLocationBar()->AcceptInput();
- nav_observer.Wait();
- return title_watcher.WaitAndGetTitle() == title;
- }
-
- GURL GetActiveTabURL() {
- return active_tab()->GetController().GetActiveEntry()->GetURL();
- }
-
- bool GetSelectionState(bool* selected) {
- return GetBoolFromJS(instant()->GetOverlayContents(),
- "google.ac.gs().api.i()", selected);
- }
-
bool IsGooglePage(content::WebContents* contents) {
bool is_google = false;
if (!GetBoolFromJS(contents, "!!window.google", &is_google))
@@ -135,8 +93,7 @@ class InstantExtendedManualTest : public InProcessBrowserTest,
IN_PROC_BROWSER_TEST_F(InstantExtendedManualTest, MANUAL_ShowsGoogleNTP) {
set_browser(browser());
- instant()->SetInstantEnabled(false, true);
- instant()->SetInstantEnabled(true, false);
+ instant()->ReloadStaleNTP();
FocusOmniboxAndWaitForInstantNTPSupport();
content::WindowedNotificationObserver observer(
@@ -155,8 +112,7 @@ IN_PROC_BROWSER_TEST_F(InstantExtendedManualTest, MANUAL_ShowsGoogleNTP) {
IN_PROC_BROWSER_TEST_F(InstantExtendedManualTest, MANUAL_SearchesFromFakebox) {
set_browser(browser());
- instant()->SetInstantEnabled(false, true);
- instant()->SetInstantEnabled(true, false);
+ instant()->ReloadStaleNTP();
FocusOmniboxAndWaitForInstantNTPSupport();
// Open a new tab page.
« no previous file with comments | « chrome/browser/ui/search/instant_extended_interactive_uitest.cc ('k') | chrome/browser/ui/search/instant_ipc_sender.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698