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

Unified Diff: content/browser/site_per_process_browsertest.cc

Issue 2523583003: Fix some flaky tests. (Closed)
Patch Set: Undo change in DOMMessageQueue. Created 4 years, 1 month 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 | content/public/test/test_frame_navigation_observer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/site_per_process_browsertest.cc
diff --git a/content/browser/site_per_process_browsertest.cc b/content/browser/site_per_process_browsertest.cc
index 477294d4ff3293afaf7946ad66680995578bb6f8..641dac150d461576e1923a9814e96f986bb82e3b 100644
--- a/content/browser/site_per_process_browsertest.cc
+++ b/content/browser/site_per_process_browsertest.cc
@@ -8357,6 +8357,8 @@ IN_PROC_BROWSER_TEST_F(SitePerProcessBrowserTest, NavigateInUnloadHandler) {
"};\n"));
// Navigate B's subframe to a cross-site C.
+ RenderFrameDeletedObserver deleted_observer(
+ root->child_at(0)->child_at(0)->current_frame_host());
std::string script =
std::string("window.document.getElementById('child-0').src = \"") +
embedded_test_server()
@@ -8367,8 +8369,6 @@ IN_PROC_BROWSER_TEST_F(SitePerProcessBrowserTest, NavigateInUnloadHandler) {
ExecuteScript(root->child_at(0)->current_frame_host(), script.c_str()));
// Wait until B's subframe RenderFrameHost is destroyed.
- RenderFrameDeletedObserver deleted_observer(
- root->child_at(0)->child_at(0)->current_frame_host());
deleted_observer.WaitUntilDeleted();
// Check that C's subframe is alive and the navigation in the unload handler
« no previous file with comments | « no previous file | content/public/test/test_frame_navigation_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698