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

Unified Diff: chrome/browser/page_load_metrics/page_load_tracker.cc

Issue 2885453003: NavigationSimulator: add support for GlobalRequestIds (Closed)
Patch Set: dcheck Created 3 years, 7 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/page_load_metrics/page_load_tracker.cc
diff --git a/chrome/browser/page_load_metrics/page_load_tracker.cc b/chrome/browser/page_load_metrics/page_load_tracker.cc
index 77d31f62cb34f6d1d91ea4d8c66f759988976674..48c06b6dd32a1c14f7e06379c2008b83059f8956 100644
--- a/chrome/browser/page_load_metrics/page_load_tracker.cc
+++ b/chrome/browser/page_load_metrics/page_load_tracker.cc
@@ -522,15 +522,7 @@ void PageLoadTracker::WebContentsShown() {
void PageLoadTracker::WillProcessNavigationResponse(
content::NavigationHandle* navigation_handle) {
- // PlzNavigate: NavigationHandle::GetGlobalRequestID() sometimes returns an
- // uninitialized GlobalRequestID. Bail early in this case. See
- // crbug.com/680841 for details.
- // TODO(jkarlin): NavigationSimulator is the first unittest framework to hit
- // this function, and it doesn't provide a GlobalRequestID. Add an ID. See
- // crbug.com/711352 for details.
- if (navigation_handle->GetGlobalRequestID() == content::GlobalRequestID())
- return;
-
+ DCHECK(navigation_handle->GetGlobalRequestID() != content::GlobalRequestID());
Charlie Reis 2017/05/15 20:07:43 This looks possibly redundant with line 528 now th
Charlie Harrison 2017/05/15 21:45:54 Done.
DCHECK(!navigation_request_id_.has_value());
navigation_request_id_ = navigation_handle->GetGlobalRequestID();
DCHECK(navigation_request_id_.value() != content::GlobalRequestID());
« no previous file with comments | « no previous file | content/public/test/navigation_simulator.cc » ('j') | content/public/test/navigation_simulator.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698