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

Unified Diff: content/browser/child_process_launcher_browsertest.cc

Issue 1309323004: Create a NavigationEntry for the initial blank page. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix GetEntryCount, more tests Created 5 years, 2 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 | « components/sessions/ios/ios_live_tab.cc ('k') | content/browser/frame_host/navigation_controller_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/child_process_launcher_browsertest.cc
diff --git a/content/browser/child_process_launcher_browsertest.cc b/content/browser/child_process_launcher_browsertest.cc
index 9ef655c6fc6ef22dd3bdb12d12e67f58135872d6..d85dc11fc99be8053e08ec87d67920bd38815ff9 100644
--- a/content/browser/child_process_launcher_browsertest.cc
+++ b/content/browser/child_process_launcher_browsertest.cc
@@ -65,17 +65,17 @@ IN_PROC_BROWSER_TEST_F(ChildProcessLauncherBrowserTest, ChildSpawnFail) {
client->simulate_failure_ = true;
nav_observer1.Wait();
delete client;
- NavigationEntry* last_entry =
- shell()->web_contents()->GetController().GetLastCommittedEntry();
// Make sure we didn't navigate.
- CHECK(!last_entry);
+ CHECK(shell()->web_contents()->GetController().IsInitialNavigation());
// Navigate again and let the process spawn correctly.
TestNavigationObserver nav_observer2(window->web_contents(), 1);
window->LoadURL(url);
nav_observer2.Wait();
- last_entry = shell()->web_contents()->GetController().GetLastCommittedEntry();
+ NavigationEntry* last_entry =
+ shell()->web_contents()->GetController().GetLastCommittedEntry();
// Make sure that we navigated to the proper URL.
+ CHECK(!shell()->web_contents()->GetController().IsInitialNavigation());
CHECK(last_entry && last_entry->GetPageType() == PAGE_TYPE_NORMAL);
CHECK(shell()->web_contents()->GetLastCommittedURL() == url);
« no previous file with comments | « components/sessions/ios/ios_live_tab.cc ('k') | content/browser/frame_host/navigation_controller_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698