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

Unified Diff: chrome/browser/ui/views/passwords/manage_passwords_bubble_view_browsertest.cc

Issue 505123002: Revert "Revert of Hook up the Mac password bubble to the browser and add browser tests. (patchset #… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix include for real this time Created 6 years, 4 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/views/passwords/manage_passwords_bubble_view_browsertest.cc
diff --git a/chrome/browser/ui/views/passwords/manage_passwords_bubble_view_browsertest.cc b/chrome/browser/ui/views/passwords/manage_passwords_bubble_view_browsertest.cc
index 2914038063be07620e16eb8c73b93dec1c992a7f..0a1a9ffeb1d4ea6c3a791a0e290efe3bb84f0c28 100644
--- a/chrome/browser/ui/views/passwords/manage_passwords_bubble_view_browsertest.cc
+++ b/chrome/browser/ui/views/passwords/manage_passwords_bubble_view_browsertest.cc
@@ -6,8 +6,12 @@
#include "base/metrics/histogram_samples.h"
#include "chrome/browser/ui/browser.h"
+#include "chrome/browser/ui/passwords/manage_passwords_test.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h"
-#include "chrome/browser/ui/views/passwords/manage_passwords_view_test.h"
+#include "chrome/browser/ui/views/frame/browser_view.h"
+#include "chrome/browser/ui/views/passwords/manage_passwords_bubble_view.h"
+#include "chrome/browser/ui/views/passwords/manage_passwords_icon_view.h"
+#include "chrome/browser/ui/views/toolbar/toolbar_view.h"
#include "chrome/test/base/interactive_test_utils.h"
#include "components/password_manager/core/browser/password_manager_metrics_util.h"
#include "components/password_manager/core/browser/stub_password_manager_client.h"
@@ -19,9 +23,24 @@ const char kDisplayDispositionMetric[] = "PasswordBubble.DisplayDisposition";
} // namespace
-typedef ManagePasswordsViewTest ManagePasswordsBubbleViewTest;
namespace metrics_util = password_manager::metrics_util;
+class ManagePasswordsBubbleViewTest : public ManagePasswordsTest {
+ public:
+ ManagePasswordsBubbleViewTest() {}
+ virtual ~ManagePasswordsBubbleViewTest() {}
+
+ virtual ManagePasswordsIcon* view() OVERRIDE {
+ BrowserView* browser_view = static_cast<BrowserView*>(browser()->window());
+ return browser_view->GetToolbarView()
+ ->location_bar()
+ ->manage_passwords_icon_view();
+ }
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(ManagePasswordsBubbleViewTest);
+};
+
IN_PROC_BROWSER_TEST_F(ManagePasswordsBubbleViewTest, BasicOpenAndClose) {
EXPECT_FALSE(ManagePasswordsBubbleView::IsShowing());
ManagePasswordsBubbleView::ShowBubble(

Powered by Google App Engine
This is Rietveld 408576698