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

Unified Diff: chrome/browser/policy/policy_browsertest.cc

Issue 2366843002: Fix two Chrome Apps browser tests with PlzNavigate. (Closed)
Patch Set: Created 4 years, 3 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/test/data/extensions/platform_apps/window_api/test.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/policy/policy_browsertest.cc
diff --git a/chrome/browser/policy/policy_browsertest.cc b/chrome/browser/policy/policy_browsertest.cc
index 3f48807728804af2afebf533bd3f35a21f64a875..ad31d28324cd8bbfc5563bd07d91efc5568ca936 100644
--- a/chrome/browser/policy/policy_browsertest.cc
+++ b/chrome/browser/policy/policy_browsertest.cc
@@ -2550,6 +2550,11 @@ IN_PROC_BROWSER_TEST_F(PolicyTest, FullscreenAllowedApp) {
// Verify that the window is not in fullscreen mode.
EXPECT_FALSE(window->GetBaseWindow()->IsFullscreen());
+ // For PlzNavigate case, we have to wait for the navigation to commit since
+ // the JS object registration is delayed (see
+ // AppWindowCreateFunction::RunAsync).
+ content::WaitForLoadStop(window->web_contents());
+
// Verify that the window cannot be toggled into fullscreen mode via apps
// APIs.
EXPECT_TRUE(content::ExecuteScript(
« no previous file with comments | « no previous file | chrome/test/data/extensions/platform_apps/window_api/test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698