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

Unified Diff: chrome/browser/ssl/ssl_browser_tests.cc

Issue 1799163002: Remove swapped out state from RenderFrameHost. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing failing layout test and adding an explicit test. Created 4 years, 9 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
Index: chrome/browser/ssl/ssl_browser_tests.cc
diff --git a/chrome/browser/ssl/ssl_browser_tests.cc b/chrome/browser/ssl/ssl_browser_tests.cc
index 0f0c4656d414f90b1d0ac19b2d451207fa3b39ee..7bbf781fdc09be43ce372c05ec780be0c96e5633 100644
--- a/chrome/browser/ssl/ssl_browser_tests.cc
+++ b/chrome/browser/ssl/ssl_browser_tests.cc
@@ -928,6 +928,7 @@ IN_PROC_BROWSER_TEST_F(SSLUITest,
browser(), embedded_test_server()->GetURL("/ssl/google.html"));
WebContents* tab = browser()->tab_strip_model()->GetActiveWebContents();
NavigationEntry* entry = tab->GetController().GetActiveEntry();
+ content::RenderFrameHost* rfh = tab->GetMainFrame();
ASSERT_TRUE(entry);
// Now go to a bad HTTPS page that shows an interstitial.
@@ -941,13 +942,10 @@ IN_PROC_BROWSER_TEST_F(SSLUITest,
// Simulate user clicking on back button (crbug.com/39248).
chrome::GoBack(browser(), CURRENT_TAB);
- // Wait until we hear the load failure, and make sure we haven't swapped out
- // the previous page. Prevents regression of http://crbug.com/82667.
- // TODO(creis/nick): Move the swapped-out part of this test into content
- // and remove IsRenderViewHostSwappedOut from the public API.
+ // Wait until we hear the load failure, and make sure we haven't changed
+ // the previous RFH. Prevents regression of http://crbug.com/82667.
load_failed_observer.Wait();
- EXPECT_FALSE(content::RenderFrameHostTester::IsRenderFrameHostSwappedOut(
- tab->GetMainFrame()));
+ EXPECT_EQ(rfh, tab->GetMainFrame());
// We should be back at the original good page.
EXPECT_FALSE(browser()->tab_strip_model()->GetActiveWebContents()->
« no previous file with comments | « no previous file | content/browser/frame_host/navigator_impl.cc » ('j') | content/browser/frame_host/render_frame_host_impl.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698