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

Side by Side Diff: content/test/content_browser_test_utils_internal.cc

Issue 1797363002: "Top Document Isolation" mode (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Suppress tests under --site-per-process Created 4 years, 8 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 unified diff | Download patch
« no previous file with comments | « content/public/common/content_switches.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/test/content_browser_test_utils_internal.h" 5 #include "content/test/content_browser_test_utils_internal.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <map> 10 #include <map>
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 if (node != root) 203 if (node != root)
204 result.append("\n"); 204 result.append("\n");
205 result.append(line); 205 result.append(line);
206 } 206 }
207 207
208 // Finally, show a legend with details of the site instances. 208 // Finally, show a legend with details of the site instances.
209 const char* prefix = "Where "; 209 const char* prefix = "Where ";
210 for (auto& legend_entry : legend) { 210 for (auto& legend_entry : legend) {
211 SiteInstanceImpl* site_instance = 211 SiteInstanceImpl* site_instance =
212 static_cast<SiteInstanceImpl*>(legend_entry.second); 212 static_cast<SiteInstanceImpl*>(legend_entry.second);
213 std::string description = site_instance->GetSiteURL().spec();
214 if (site_instance->is_default_subframe_site_instance())
215 description = "default subframe process";
213 base::StringAppendF(&result, "\n%s%s = %s", prefix, 216 base::StringAppendF(&result, "\n%s%s = %s", prefix,
214 legend_entry.first.c_str(), 217 legend_entry.first.c_str(), description.c_str());
215 site_instance->GetSiteURL().spec().c_str());
216 // Highlight some exceptionable conditions. 218 // Highlight some exceptionable conditions.
217 if (site_instance->active_frame_count() == 0) 219 if (site_instance->active_frame_count() == 0)
218 result.append(" (active_frame_count == 0)"); 220 result.append(" (active_frame_count == 0)");
219 if (!site_instance->GetProcess()->HasConnection()) 221 if (!site_instance->GetProcess()->HasConnection())
220 result.append(" (no process)"); 222 result.append(" (no process)");
221 prefix = " "; 223 prefix = " ";
222 } 224 }
223 return result; 225 return result;
224 } 226 }
225 227
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
319 content::ResourceContext* resource_context, 321 content::ResourceContext* resource_context,
320 content::AppCacheService* appcache_service, 322 content::AppCacheService* appcache_service,
321 ResourceType resource_type, 323 ResourceType resource_type,
322 ScopedVector<content::ResourceThrottle>* throttles) { 324 ScopedVector<content::ResourceThrottle>* throttles) {
323 DCHECK_CURRENTLY_ON(content::BrowserThread::IO); 325 DCHECK_CURRENTLY_ON(content::BrowserThread::IO);
324 if (request->url() == url_) 326 if (request->url() == url_)
325 throttles->push_back(new HttpRequestStallThrottle); 327 throttles->push_back(new HttpRequestStallThrottle);
326 } 328 }
327 329
328 } // namespace content 330 } // namespace content
OLDNEW
« no previous file with comments | « content/public/common/content_switches.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698