Index: content/browser/renderer_host/resource_dispatcher_host_unittest.cc |
diff --git a/content/browser/renderer_host/resource_dispatcher_host_unittest.cc b/content/browser/renderer_host/resource_dispatcher_host_unittest.cc |
index 1b5770362e2bf836ac3cbfa4731a6278f18aff09..39207383b45193f942a48b3ce1a146d45dbbcca1 100644 |
--- a/content/browser/renderer_host/resource_dispatcher_host_unittest.cc |
+++ b/content/browser/renderer_host/resource_dispatcher_host_unittest.cc |
@@ -13,6 +13,7 @@ |
#include "content/browser/browser_thread.h" |
#include "content/browser/child_process_security_policy.h" |
#include "content/browser/download/download_id.h" |
+#include "content/browser/download/download_id_factory.h" |
#include "content/browser/mock_resource_context.h" |
#include "content/browser/renderer_host/dummy_resource_handler.h" |
#include "content/browser/renderer_host/global_request_id.h" |
@@ -1161,8 +1162,10 @@ TEST_F(ResourceDispatcherHostTest, IgnoreCancelForDownloads) { |
HandleScheme("http"); |
MakeTestRequest(render_view_id, request_id, GURL("http://example.com/blah")); |
- content::MockResourceContext::GetInstance()->set_next_download_id_thunk( |
- base::Bind(&MockNextDownloadId)); |
+ scoped_refptr<DownloadIdFactory> id_factory( |
+ new DownloadIdFactory("valid DownloadId::Domain")); |
+ content::MockResourceContext::GetInstance()->set_download_id_factory( |
+ id_factory); |
// Return some data so that the request is identified as a download |
// and the proper resource handlers are created. |
EXPECT_TRUE(net::URLRequestTestJob::ProcessOnePendingMessage()); |
@@ -1198,8 +1201,10 @@ TEST_F(ResourceDispatcherHostTest, CancelRequestsForContext) { |
HandleScheme("http"); |
MakeTestRequest(render_view_id, request_id, GURL("http://example.com/blah")); |
- content::MockResourceContext::GetInstance()->set_next_download_id_thunk( |
- base::Bind(&MockNextDownloadId)); |
+ scoped_refptr<DownloadIdFactory> id_factory( |
+ new DownloadIdFactory("valid DownloadId::Domain")); |
+ content::MockResourceContext::GetInstance()->set_download_id_factory( |
+ id_factory); |
// Return some data so that the request is identified as a download |
// and the proper resource handlers are created. |
EXPECT_TRUE(net::URLRequestTestJob::ProcessOnePendingMessage()); |