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

Unified Diff: chrome/browser/automation/url_request_mock_http_job.cc

Issue 15010: Implement extension:// protocol. (Closed)
Patch Set: add missing unit test Created 12 years 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/automation/url_request_mock_http_job.cc
diff --git a/chrome/browser/automation/url_request_mock_http_job.cc b/chrome/browser/automation/url_request_mock_http_job.cc
index 9f2ccfcc6f700df8829fe50d314968e1025d503d..ed384e68b5af6220bf463f96be45933505f5c2e7 100644
--- a/chrome/browser/automation/url_request_mock_http_job.cc
+++ b/chrome/browser/automation/url_request_mock_http_job.cc
@@ -33,9 +33,8 @@ URLRequestJob* URLRequestMockHTTPJob::Factory(URLRequest* request,
// Convert the file:/// URL to a path on disk.
std::wstring file_path;
net::FileURLToFilePath(GURL(WideToUTF8(file_url)), &file_path);
- URLRequestMockHTTPJob* job = new URLRequestMockHTTPJob(request);
- job->file_path_ = FilePath::FromWStringHack(file_path);
- return job;
+ return new URLRequestMockHTTPJob(request,
+ FilePath::FromWStringHack(file_path));
}
/* static */
@@ -57,8 +56,9 @@ GURL URLRequestMockHTTPJob::GetMockUrl(const std::wstring& path) {
return GURL(url);
}
-URLRequestMockHTTPJob::URLRequestMockHTTPJob(URLRequest* request)
- : URLRequestFileJob(request) { }
+URLRequestMockHTTPJob::URLRequestMockHTTPJob(URLRequest* request,
+ const FilePath& file_path)
+ : URLRequestFileJob(request, file_path) { }
void URLRequestMockHTTPJob::GetResponseInfo(net::HttpResponseInfo* info) {
std::wstring header_file = file_path_.ToWStringHack() + kMockHeaderFileSuffix;
« no previous file with comments | « chrome/browser/automation/url_request_mock_http_job.h ('k') | chrome/browser/automation/url_request_mock_net_error_job.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698