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

Unified Diff: content/test/browser_test_utils_browsertest.cc

Issue 2652413003: Convert CrossSiteRedirectorBrowserTest to use the new navigation callbacks. (Closed)
Patch Set: Created 3 years, 11 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/test/browser_test_utils_browsertest.cc
diff --git a/content/test/browser_test_utils_browsertest.cc b/content/test/browser_test_utils_browsertest.cc
index 30faa2b628a6cee2bf5b4d818a70d662e5ec1df1..9303cd3d9a1d781e7e78efc07a9ca69bb112b11a 100644
--- a/content/test/browser_test_utils_browsertest.cc
+++ b/content/test/browser_test_utils_browsertest.cc
@@ -20,11 +20,9 @@ class NavigationObserver: public WebContentsObserver {
: WebContentsObserver(web_contents) {}
~NavigationObserver() override {}
- void DidCommitProvisionalLoadForFrame(
- RenderFrameHost* render_frame_host,
- const GURL& url,
- ui::PageTransition transition_type) override {
- navigation_url_ = url;
+ void DidFinishNavigation(NavigationHandle* navigation_handle) override {
+ if (navigation_handle->HasCommitted())
nasko 2017/01/27 00:25:07 Should we use the same approach as the other CL to
jam 2017/01/27 00:37:08 since 1) it doesn't matter in this case since it's
+ navigation_url_ = navigation_handle->GetURL();
}
void DidRedirectNavigation(NavigationHandle* handle) override {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698