OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "public/web/WebEmbeddedWorker.h" | 5 #include "public/web/WebEmbeddedWorker.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include "platform/testing/URLTestHelpers.h" | 8 #include "platform/testing/URLTestHelpers.h" |
9 #include "platform/testing/UnitTestHelpers.h" | 9 #include "platform/testing/UnitTestHelpers.h" |
10 #include "platform/wtf/PtrUtil.h" | 10 #include "platform/wtf/PtrUtil.h" |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 void Focus(const WebString& uuid, | 64 void Focus(const WebString& uuid, |
65 std::unique_ptr<WebServiceWorkerClientCallbacks>) override { | 65 std::unique_ptr<WebServiceWorkerClientCallbacks>) override { |
66 NOTREACHED(); | 66 NOTREACHED(); |
67 } | 67 } |
68 void Navigate(const WebString& uuid, | 68 void Navigate(const WebString& uuid, |
69 const WebURL&, | 69 const WebURL&, |
70 std::unique_ptr<WebServiceWorkerClientCallbacks>) override { | 70 std::unique_ptr<WebServiceWorkerClientCallbacks>) override { |
71 NOTREACHED(); | 71 NOTREACHED(); |
72 } | 72 } |
73 void RegisterForeignFetchScopes( | 73 void RegisterForeignFetchScopes( |
| 74 int event_id, |
74 const WebVector<WebURL>& sub_scopes, | 75 const WebVector<WebURL>& sub_scopes, |
75 const WebVector<WebSecurityOrigin>& origins) override { | 76 const WebVector<WebSecurityOrigin>& origins) override { |
76 NOTREACHED(); | 77 NOTREACHED(); |
77 } | 78 } |
78 | 79 |
79 private: | 80 private: |
80 bool has_associated_registration_; | 81 bool has_associated_registration_; |
81 }; | 82 }; |
82 | 83 |
83 class WebEmbeddedWorkerImplTest : public ::testing::Test { | 84 class WebEmbeddedWorkerImplTest : public ::testing::Test { |
(...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
286 ::testing::Mock::VerifyAndClearExpectations(mock_client_); | 287 ::testing::Mock::VerifyAndClearExpectations(mock_client_); |
287 | 288 |
288 // Resume after download. | 289 // Resume after download. |
289 EXPECT_CALL(*mock_client_, CreateServiceWorkerProvider()) | 290 EXPECT_CALL(*mock_client_, CreateServiceWorkerProvider()) |
290 .WillOnce(::testing::Return(nullptr)); | 291 .WillOnce(::testing::Return(nullptr)); |
291 worker_->ResumeAfterDownload(); | 292 worker_->ResumeAfterDownload(); |
292 ::testing::Mock::VerifyAndClearExpectations(mock_client_); | 293 ::testing::Mock::VerifyAndClearExpectations(mock_client_); |
293 } | 294 } |
294 | 295 |
295 } // namespace blink | 296 } // namespace blink |
OLD | NEW |