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

Unified Diff: chrome/browser/ui/autofill/autofill_popup_controller_interactive_uitest.cc

Issue 870833002: [android] Autofill popup behavior fixes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update expectations of old test and add a new test. Created 5 years, 11 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
« no previous file with comments | « no previous file | chrome/browser/ui/autofill/chrome_autofill_client.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/autofill/autofill_popup_controller_interactive_uitest.cc
diff --git a/chrome/browser/ui/autofill/autofill_popup_controller_interactive_uitest.cc b/chrome/browser/ui/autofill/autofill_popup_controller_interactive_uitest.cc
index 977122aeb6bb19fc7745337e878d55afeabf1b5a..7ba0e02ce3a231b641bbda3b56492f496651ef41 100644
--- a/chrome/browser/ui/autofill/autofill_popup_controller_interactive_uitest.cc
+++ b/chrome/browser/ui/autofill/autofill_popup_controller_interactive_uitest.cc
@@ -96,23 +96,33 @@ class AutofillPopupControllerBrowserTest
scoped_ptr<TestAutofillExternalDelegate> autofill_external_delegate_;
};
-// Autofill UI isn't currently hidden on window move on Mac.
-// http://crbug.com/180566
-#if !defined(OS_MACOSX)
IN_PROC_BROWSER_TEST_F(AutofillPopupControllerBrowserTest,
- HidePopupOnWindowConfiguration) {
+ DoNotHidePopupOnWindowMove) {
GenerateTestAutofillPopup(autofill_external_delegate_.get());
EXPECT_FALSE(autofill_external_delegate_->popup_hidden());
- // Resize the window, which should cause the popup to hide.
+ // Move the window, which should not cause the popup to hide.
gfx::Rect new_bounds = browser()->window()->GetBounds() - gfx::Vector2d(1, 1);
browser()->window()->SetBounds(new_bounds);
+ EXPECT_FALSE(autofill_external_delegate_->popup_hidden());
+}
+
+IN_PROC_BROWSER_TEST_F(AutofillPopupControllerBrowserTest,
+ HidePopupOnWindowResize) {
+ GenerateTestAutofillPopup(autofill_external_delegate_.get());
+
+ EXPECT_FALSE(autofill_external_delegate_->popup_hidden());
+
+ // Resize the window, which should cause the popup to hide.
+ gfx::Rect new_bounds = browser()->window()->GetBounds();
+ new_bounds.Inset(1, 1);
+ browser()->window()->SetBounds(new_bounds);
+
autofill_external_delegate_->WaitForPopupHidden();
EXPECT_TRUE(autofill_external_delegate_->popup_hidden());
}
-#endif // !defined(OS_MACOSX)
// This test checks that the browser doesn't crash if the delegate is deleted
// before the popup is hidden.
« no previous file with comments | « no previous file | chrome/browser/ui/autofill/chrome_autofill_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698