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

Unified Diff: content/browser/frame_host/render_frame_host_manager_unittest.cc

Issue 88503002: Have the unload event execute in background on cross-site navigations (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Keeping the old rvh alive for up to 1s Created 7 years 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: content/browser/frame_host/render_frame_host_manager_unittest.cc
diff --git a/content/browser/frame_host/render_frame_host_manager_unittest.cc b/content/browser/frame_host/render_frame_host_manager_unittest.cc
index 2ba5fb8493ac5b7e58cdca68f655ae18a118858e..a8fcaa75ef7099739925eb7c0aadbdeb6f6fd34b 100644
--- a/content/browser/frame_host/render_frame_host_manager_unittest.cc
+++ b/content/browser/frame_host/render_frame_host_manager_unittest.cc
@@ -128,7 +128,7 @@ class RenderFrameHostManagerTest
// Simulate the SwapOut_ACK that fires if you commit a cross-site
// navigation.
if (old_rvh != active_rvh())
- old_rvh->OnSwappedOut(false);
+ old_rvh->OnSwappedOut(false, false);
active_test_rvh()->SendNavigate(max_page_id + 1, url);
}
@@ -219,7 +219,7 @@ TEST_F(RenderFrameHostManagerTest, NewTabPageProcesses) {
ASSERT_TRUE(dest_rvh2);
ntp_rvh2->SendShouldCloseACK(true);
- ntp_rvh2->OnSwappedOut(false);
+ ntp_rvh2->OnSwappedOut(false, false);
dest_rvh2->SendNavigate(101, kDestUrl);
// The two RVH's should be different in every way.
@@ -235,7 +235,7 @@ TEST_F(RenderFrameHostManagerTest, NewTabPageProcesses) {
contents2->GetController().LoadURL(
kChromeUrl, Referrer(), PAGE_TRANSITION_LINK, std::string());
dest_rvh2->SendShouldCloseACK(true);
- dest_rvh2->OnSwappedOut(false);
+ dest_rvh2->OnSwappedOut(false, false);
static_cast<TestRenderViewHost*>(contents2->GetRenderManagerForTesting()->
pending_render_view_host())->SendNavigate(102, kChromeUrl);
@@ -759,7 +759,7 @@ TEST_F(RenderFrameHostManagerTest, NavigateWithEarlyReNavigation) {
manager.SwapOutOldPage();
EXPECT_TRUE(test_process_host->sink().GetUniqueMessageMatching(
ViewMsg_SwapOut::ID));
- test_host->OnSwappedOut(false);
+ test_host->OnSwappedOut(false, false);
EXPECT_EQ(host, manager.current_host());
EXPECT_FALSE(static_cast<RenderViewHostImpl*>(
@@ -805,7 +805,7 @@ TEST_F(RenderFrameHostManagerTest, NavigateWithEarlyReNavigation) {
manager.SwapOutOldPage();
EXPECT_TRUE(test_process_host->sink().GetUniqueMessageMatching(
ViewMsg_SwapOut::ID));
- test_host->OnSwappedOut(false);
+ test_host->OnSwappedOut(false, false);
// Commit.
manager.DidNavigateMainFrame(host3);

Powered by Google App Engine
This is Rietveld 408576698