Index: content/browser/service_worker/service_worker_provider_host_unittest.cc |
diff --git a/content/browser/service_worker/service_worker_provider_host_unittest.cc b/content/browser/service_worker/service_worker_provider_host_unittest.cc |
index 36381affadde29b0d594146725220f44fa1125e6..57cd41d2dd91bbcc08123ff704eeb0bdc6afdad0 100644 |
--- a/content/browser/service_worker/service_worker_provider_host_unittest.cc |
+++ b/content/browser/service_worker/service_worker_provider_host_unittest.cc |
@@ -57,19 +57,19 @@ class ServiceWorkerProviderHostTest : public testing::Test { |
GURL("https://other.example.com/"), 3L, context_->AsWeakPtr()); |
// Prepare provider hosts (for the same process). |
- std::unique_ptr<ServiceWorkerProviderHost> host1( |
- new ServiceWorkerProviderHost( |
- helper_->mock_render_process_id(), MSG_ROUTING_NONE, |
- 1 /* provider_id */, SERVICE_WORKER_PROVIDER_FOR_WINDOW, |
- ServiceWorkerProviderHost::FrameSecurityLevel::SECURE, |
- context_->AsWeakPtr(), NULL)); |
+ std::unique_ptr<ServiceWorkerProviderHost> host1 = |
+ ServiceWorkerProviderHost::CreateForTesting( |
+ helper_->mock_render_process_id(), 1 /* provider_id */, |
+ SERVICE_WORKER_PROVIDER_FOR_WINDOW, |
+ helper_->context()->AsWeakPtr()); |
+ host1->set_parent_frame_secure(true); |
host1->SetDocumentUrl(GURL("https://www.example.com/example1.html")); |
- std::unique_ptr<ServiceWorkerProviderHost> host2( |
- new ServiceWorkerProviderHost( |
- helper_->mock_render_process_id(), MSG_ROUTING_NONE, |
- 2 /* provider_id */, SERVICE_WORKER_PROVIDER_FOR_WINDOW, |
- ServiceWorkerProviderHost::FrameSecurityLevel::SECURE, |
- context_->AsWeakPtr(), NULL)); |
+ std::unique_ptr<ServiceWorkerProviderHost> host2 = |
+ ServiceWorkerProviderHost::CreateForTesting( |
+ helper_->mock_render_process_id(), 2 /* provider_id */, |
+ SERVICE_WORKER_PROVIDER_FOR_WINDOW, |
+ helper_->context()->AsWeakPtr()); |
+ host2->set_parent_frame_secure(true); |
host2->SetDocumentUrl(GURL("https://www.example.com/example2.html")); |
provider_host1_ = host1->AsWeakPtr(); |
provider_host2_ = host2->AsWeakPtr(); |