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

Unified Diff: content/test/net/url_request_failed_job.h

Issue 24503004: Show IDN in error screens (DNS failure etc.) (Closed) Base URL: https://src.chromium.org/chrome/trunk/src/
Patch Set: Created 7 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 | « content/renderer/render_view_impl.cc ('k') | content/test/net/url_request_failed_job.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/test/net/url_request_failed_job.h
===================================================================
--- content/test/net/url_request_failed_job.h (revision 226965)
+++ content/test/net/url_request_failed_job.h (working copy)
@@ -26,6 +26,7 @@
// Adds the testing URLs to the net::URLRequestFilter.
static void AddUrlHandler();
+ static void AddUrlHandlerForHostname(const std::string& hostname);
// Given a net error code, constructs a mock URL that will return that error
// asynchronously when started. |net_error| must be a valid net error code
@@ -33,6 +34,13 @@
static GURL GetMockHttpUrl(int net_error);
static GURL GetMockHttpsUrl(int net_error);
+ // URLRequestFailedJob must be added as a handler for |hostname| for
+ // the returned URL to return |net_error|.
+ static GURL GetMockHttpUrlForHostname(int net_error,
+ const std::string& hostname);
+ static GURL GetMockHttpsUrlForHostname(int net_error,
+ const std::string& hostname);
+
private:
static net::URLRequestJob* Factory(net::URLRequest* request,
net::NetworkDelegate* network_delegate,
« no previous file with comments | « content/renderer/render_view_impl.cc ('k') | content/test/net/url_request_failed_job.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698