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

Unified Diff: chrome/browser/ui/webui/options/options_ui_browsertest.cc

Issue 302293002: Fix ClearBrowserDataBrowserTest.CommitButtonDisabledWhileDeletionInProgress flake. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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 | « chrome/browser/ui/webui/options/clear_browser_data_browsertest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/options/options_ui_browsertest.cc
diff --git a/chrome/browser/ui/webui/options/options_ui_browsertest.cc b/chrome/browser/ui/webui/options/options_ui_browsertest.cc
index 0313cc4dc807768ea539470a91e448dd47a52524..5d8a70ad958d0a11769a3e23e671b4538eaf3a0b 100644
--- a/chrome/browser/ui/webui/options/options_ui_browsertest.cc
+++ b/chrome/browser/ui/webui/options/options_ui_browsertest.cc
@@ -130,6 +130,13 @@ void OptionsUIBrowserTest::NavigateToSettingsSubpage(
subscription = options_ui->RegisterOnFinishedLoadingCallback(
message_loop_runner->QuitClosure());
message_loop_runner->Run();
+
+ // The OnFinishedLoading event, which indicates that all WebUI initialization
+ // methods have been called on the JS side, is temporally unrelated to whether
+ // or not the WebContents considers itself to have finished loading. We want
+ // to wait for this too, however, because, e.g. this is a sufficient condition
+ // to get the focus properly placed on a form element.
+ content::WaitForLoadStop(web_contents);
}
void OptionsUIBrowserTest::NavigateToSettingsFrame() {
« no previous file with comments | « chrome/browser/ui/webui/options/clear_browser_data_browsertest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698