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

Unified Diff: content/browser/presentation/presentation_service_impl_unittest.cc

Issue 2379703002: [Presentation API] (alternative) 1-UA: send message between controller and receiver page (Closed)
Patch Set: resolve code review comments from Mark Created 4 years, 2 months 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: content/browser/presentation/presentation_service_impl_unittest.cc
diff --git a/content/browser/presentation/presentation_service_impl_unittest.cc b/content/browser/presentation/presentation_service_impl_unittest.cc
index bb5bcc14afcda5e2a97c1354671cb06c09019321..0796b5747a6f7c3d0fe3fe9d662ed67437337ee1 100644
--- a/content/browser/presentation/presentation_service_impl_unittest.cc
+++ b/content/browser/presentation/presentation_service_impl_unittest.cc
@@ -146,6 +146,22 @@ class MockPresentationServiceDelegate : public PresentationServiceDelegate {
const content::PresentationSessionInfo& connection,
const content::PresentationConnectionStateChangedCallback&
state_changed_cb));
+ MOCK_METHOD1(RegisterReceiverAvailableCallback,
mark a. foltz 2016/10/08 00:33:42 Please add unit tests for the new APIs added in Pr
zhaobin 2016/10/12 02:27:33 Done.
+ void(const content::ReceiverConnectionAvailableCallback&));
+ void RegisterOffscreenPresentationConnection(
+ int render_process_id,
+ int render_frame_id,
+ const PresentationSessionInfo& session,
+ PresentationConnectionPtr connection) override {
+ RegisterOffscreenPresentationConnectionRaw(
+ render_process_id, render_frame_id, session, connection.get());
+ }
+
+ MOCK_METHOD4(RegisterOffscreenPresentationConnectionRaw,
+ void(int render_process_id,
+ int render_frame_id,
+ const PresentationSessionInfo& session,
+ blink::mojom::PresentationConnection* connection));
void set_screen_availability_listening_supported(bool value) {
screen_availability_listening_supported_ = value;
@@ -198,7 +214,8 @@ class MockPresentationServiceClient
void(const blink::mojom::PresentationSessionInfo& session_info));
void OnReceiverConnectionAvailable(
- blink::mojom::PresentationSessionInfoPtr session_info) override {
+ blink::mojom::PresentationSessionInfoPtr session_info,
+ blink::mojom::PresentationConnectionPtr connection) override {
OnReceiverConnectionAvailable(*session_info);
}
MOCK_METHOD1(OnReceiverConnectionAvailable,

Powered by Google App Engine
This is Rietveld 408576698