Index: webkit/support/weburl_loader_mock_factory.h |
=================================================================== |
--- webkit/support/weburl_loader_mock_factory.h (revision 148351) |
+++ webkit/support/weburl_loader_mock_factory.h (working copy) |
@@ -43,6 +43,11 @@ |
const WebKit::WebURLResponse& response, |
const WebKit::WebString& filePath); |
+ // Registers an error to be served when the specified URL is requested. |
+ void RegisterErrorURL(const WebKit::WebURL& url, |
+ const WebKit::WebURLResponse& response, |
+ const WebKit::WebURLError& error); |
+ |
// Unregisters |url| so it will no longer be mocked. |
void UnregisterURL(const WebKit::WebURL& url); |
@@ -90,6 +95,9 @@ |
typedef std::map<WebURLLoaderMock*, WebKit::WebURLRequest> LoaderToRequestMap; |
LoaderToRequestMap pending_loaders_; |
+ typedef std::map<WebKit::WebURL, WebKit::WebURLError> URLToErrorMap; |
+ URLToErrorMap url_to_error_info_; |
+ |
// Table of the registered URLs and the responses that they should receive. |
typedef std::map<WebKit::WebURL, ResponseInfo> URLToResponseMap; |
URLToResponseMap url_to_reponse_info_; |