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

Side by Side Diff: chrome/browser/password_manager/password_generation_interactive_uitest.cc

Issue 366813007: Removed InProcessBrowserTest::CleanUpOnMainThread() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Removed superfluous override. Created 6 years, 5 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/command_line.h" 5 #include "base/command_line.h"
6 #include "chrome/browser/password_manager/chrome_password_manager_client.h" 6 #include "chrome/browser/password_manager/chrome_password_manager_client.h"
7 #include "chrome/browser/profiles/profile.h" 7 #include "chrome/browser/profiles/profile.h"
8 #include "chrome/browser/ui/autofill/password_generation_popup_observer.h" 8 #include "chrome/browser/ui/autofill/password_generation_popup_observer.h"
9 #include "chrome/browser/ui/browser.h" 9 #include "chrome/browser/ui/browser.h"
10 #include "chrome/browser/ui/tabs/tab_strip_model.h" 10 #include "chrome/browser/ui/tabs/tab_strip_model.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 // Set observer for popup. 67 // Set observer for popup.
68 ChromePasswordManagerClient* client = 68 ChromePasswordManagerClient* client =
69 ChromePasswordManagerClient::FromWebContents(GetWebContents()); 69 ChromePasswordManagerClient::FromWebContents(GetWebContents());
70 client->SetTestObserver(&observer_); 70 client->SetTestObserver(&observer_);
71 71
72 ASSERT_TRUE(embedded_test_server()->InitializeAndWaitUntilReady()); 72 ASSERT_TRUE(embedded_test_server()->InitializeAndWaitUntilReady());
73 GURL url = embedded_test_server()->GetURL("/password/signup_form.html"); 73 GURL url = embedded_test_server()->GetURL("/password/signup_form.html");
74 ui_test_utils::NavigateToURL(browser(), url); 74 ui_test_utils::NavigateToURL(browser(), url);
75 } 75 }
76 76
77 virtual void CleanUpOnMainThread() OVERRIDE { 77 virtual void TearDownOnMainThread() OVERRIDE {
78 // Clean up UI. 78 // Clean up UI.
79 ChromePasswordManagerClient* client = 79 ChromePasswordManagerClient* client =
80 ChromePasswordManagerClient::FromWebContents(GetWebContents()); 80 ChromePasswordManagerClient::FromWebContents(GetWebContents());
81 client->HidePasswordGenerationPopup(); 81 client->HidePasswordGenerationPopup();
82 } 82 }
83 83
84 content::WebContents* GetWebContents() { 84 content::WebContents* GetWebContents() {
85 return browser()->tab_strip_model()->GetActiveWebContents(); 85 return browser()->tab_strip_model()->GetActiveWebContents();
86 } 86 }
87 87
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 IN_PROC_BROWSER_TEST_F(PasswordGenerationInteractiveTest, 179 IN_PROC_BROWSER_TEST_F(PasswordGenerationInteractiveTest,
180 MAYBE_PopupShownAndDismissedByScrolling) { 180 MAYBE_PopupShownAndDismissedByScrolling) {
181 FocusPasswordField(); 181 FocusPasswordField();
182 EXPECT_TRUE(GenerationPopupShowing()); 182 EXPECT_TRUE(GenerationPopupShowing());
183 183
184 ASSERT_TRUE(content::ExecuteScript(GetRenderViewHost(), 184 ASSERT_TRUE(content::ExecuteScript(GetRenderViewHost(),
185 "window.scrollTo(100, 0);")); 185 "window.scrollTo(100, 0);"));
186 186
187 EXPECT_FALSE(GenerationPopupShowing()); 187 EXPECT_FALSE(GenerationPopupShowing());
188 } 188 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698