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

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

Issue 928753003: Clean password_manager::ui::State (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merge with master Created 5 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 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 b67cfdb8454a56242105440268b5994e353db917..91a7d5b43ea24d13de73ceef26c771545a5858b7 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
@@ -116,7 +116,9 @@ IN_PROC_BROWSER_TEST_F(ManagePasswordsBubbleViewTest, CommandControlsBubble) {
IN_PROC_BROWSER_TEST_F(ManagePasswordsBubbleViewTest,
CommandExecutionInManagingState) {
SetupManagingPasswords();
+ EXPECT_FALSE(ManagePasswordsBubbleView::IsShowing());
ExecuteManagePasswordsCommand();
+ EXPECT_TRUE(ManagePasswordsBubbleView::IsShowing());
scoped_ptr<base::HistogramSamples> samples(
GetSamples(kDisplayDispositionMetric));
@@ -136,6 +138,7 @@ IN_PROC_BROWSER_TEST_F(ManagePasswordsBubbleViewTest,
CommandExecutionInAutomaticState) {
// Open with pending password: automagical!
SetupPendingPassword();
+ EXPECT_TRUE(ManagePasswordsBubbleView::IsShowing());
// Bubble should not be focused by default.
EXPECT_FALSE(ManagePasswordsBubbleView::manage_password_bubble()->
@@ -162,9 +165,11 @@ IN_PROC_BROWSER_TEST_F(ManagePasswordsBubbleViewTest,
CommandExecutionInPendingState) {
// Open once with pending password: automagical!
SetupPendingPassword();
+ EXPECT_TRUE(ManagePasswordsBubbleView::IsShowing());
ManagePasswordsBubbleView::CloseBubble();
// This opening should be measured as manual.
ExecuteManagePasswordsCommand();
+ EXPECT_TRUE(ManagePasswordsBubbleView::IsShowing());
scoped_ptr<base::HistogramSamples> samples(
GetSamples(kDisplayDispositionMetric));
@@ -183,9 +188,11 @@ IN_PROC_BROWSER_TEST_F(ManagePasswordsBubbleViewTest,
IN_PROC_BROWSER_TEST_F(ManagePasswordsBubbleViewTest,
CommandExecutionInAutomaticSaveState) {
SetupAutomaticPassword();
+ EXPECT_TRUE(ManagePasswordsBubbleView::IsShowing());
ManagePasswordsBubbleView::CloseBubble();
// Re-opening should count as manual.
ExecuteManagePasswordsCommand();
+ EXPECT_TRUE(ManagePasswordsBubbleView::IsShowing());
scoped_ptr<base::HistogramSamples> samples(
GetSamples(kDisplayDispositionMetric));

Powered by Google App Engine
This is Rietveld 408576698