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

Side by Side Diff: chrome/browser/media/router/test_helper.h

Issue 1259073004: [Presentation API] Change ListenForSessionMessages API to client-style. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update comments Created 5 years, 4 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 unified diff | Download patch
OLDNEW
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 #ifndef CHROME_BROWSER_MEDIA_ROUTER_TEST_HELPER_H_ 5 #ifndef CHROME_BROWSER_MEDIA_ROUTER_TEST_HELPER_H_
6 #define CHROME_BROWSER_MEDIA_ROUTER_TEST_HELPER_H_ 6 #define CHROME_BROWSER_MEDIA_ROUTER_TEST_HELPER_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 void SendRouteBinaryMessage( 107 void SendRouteBinaryMessage(
108 const mojo::String& media_route_id, 108 const mojo::String& media_route_id,
109 mojo::Array<uint8> data, 109 mojo::Array<uint8> data,
110 const SendRouteMessageCallback& callback) override { 110 const SendRouteMessageCallback& callback) override {
111 SendRouteBinaryMessageInternal(media_route_id, data.storage(), callback); 111 SendRouteBinaryMessageInternal(media_route_id, data.storage(), callback);
112 } 112 }
113 MOCK_METHOD3(SendRouteBinaryMessageInternal, 113 MOCK_METHOD3(SendRouteBinaryMessageInternal,
114 void(const mojo::String& media_route_id, 114 void(const mojo::String& media_route_id,
115 const std::vector<uint8>& data, 115 const std::vector<uint8>& data,
116 const SendRouteMessageCallback& callback)); 116 const SendRouteMessageCallback& callback));
117 void ListenForRouteMessages(mojo::Array<mojo::String> route_ids, 117 MOCK_METHOD2(ListenForRouteMessages,
118 const ListenForRouteMessagesCallback& callback) { 118 void(const mojo::String& route_id,
119 ListenForRouteMessagesInteral(route_ids.storage(), callback);
120 }
121 MOCK_METHOD2(ListenForRouteMessagesInteral,
122 void(const std::vector<mojo::String>& route_ids,
123 const ListenForRouteMessagesCallback& callback)); 119 const ListenForRouteMessagesCallback& callback));
124 MOCK_METHOD1(ClearIssue, void(const mojo::String& issue_id)); 120 MOCK_METHOD1(ClearIssue, void(const mojo::String& issue_id));
125 MOCK_METHOD0(StartObservingMediaRoutes, void()); 121 MOCK_METHOD0(StartObservingMediaRoutes, void());
126 MOCK_METHOD0(StopObservingMediaRoutes, void()); 122 MOCK_METHOD0(StopObservingMediaRoutes, void());
127 123
128 private: 124 private:
129 DISALLOW_COPY_AND_ASSIGN(MockMediaRouteProvider); 125 DISALLOW_COPY_AND_ASSIGN(MockMediaRouteProvider);
130 }; 126 };
131 127
132 class MockMediaSinksObserver : public MediaSinksObserver { 128 class MockMediaSinksObserver : public MediaSinksObserver {
(...skipping 19 matching lines...) Expand all
152 148
153 MOCK_METHOD1(IsEventPageSuspended, bool(const std::string& extension_id)); 149 MOCK_METHOD1(IsEventPageSuspended, bool(const std::string& extension_id));
154 MOCK_METHOD2(WakeEventPage, 150 MOCK_METHOD2(WakeEventPage,
155 bool(const std::string& extension_id, 151 bool(const std::string& extension_id,
156 const base::Callback<void(bool)>& callback)); 152 const base::Callback<void(bool)>& callback));
157 }; 153 };
158 154
159 } // namespace media_router 155 } // namespace media_router
160 156
161 #endif // CHROME_BROWSER_MEDIA_ROUTER_TEST_HELPER_H_ 157 #endif // CHROME_BROWSER_MEDIA_ROUTER_TEST_HELPER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698