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

Side by Side Diff: remoting/host/host_mock_objects.h

Issue 2162083003: Renaming Gnubby and RemoteSecurityKey files/classes/members (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing a GYP build error Created 4 years, 5 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
« no previous file with comments | « remoting/host/BUILD.gn ('k') | remoting/host/host_mock_objects.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 REMOTING_HOST_HOST_MOCK_OBJECTS_H_ 5 #ifndef REMOTING_HOST_HOST_MOCK_OBJECTS_H_
6 #define REMOTING_HOST_HOST_MOCK_OBJECTS_H_ 6 #define REMOTING_HOST_HOST_MOCK_OBJECTS_H_
7 7
8 #include <cstdint> 8 #include <cstdint>
9 #include <memory> 9 #include <memory>
10 #include <string> 10 #include <string>
11 11
12 #include "base/macros.h" 12 #include "base/macros.h"
13 #include "net/base/ip_endpoint.h" 13 #include "net/base/ip_endpoint.h"
14 #include "remoting/host/chromoting_host_context.h" 14 #include "remoting/host/chromoting_host_context.h"
15 #include "remoting/host/client_session.h" 15 #include "remoting/host/client_session.h"
16 #include "remoting/host/client_session_control.h" 16 #include "remoting/host/client_session_control.h"
17 #include "remoting/host/client_session_details.h" 17 #include "remoting/host/client_session_details.h"
18 #include "remoting/host/desktop_environment.h" 18 #include "remoting/host/desktop_environment.h"
19 #include "remoting/host/host_status_observer.h" 19 #include "remoting/host/host_status_observer.h"
20 #include "remoting/host/input_injector.h" 20 #include "remoting/host/input_injector.h"
21 #include "remoting/host/screen_controls.h" 21 #include "remoting/host/screen_controls.h"
22 #include "remoting/host/screen_resolution.h" 22 #include "remoting/host/screen_resolution.h"
23 #include "remoting/host/security_key/gnubby_auth_handler.h" 23 #include "remoting/host/security_key/security_key_auth_handler.h"
24 #include "remoting/proto/control.pb.h" 24 #include "remoting/proto/control.pb.h"
25 #include "remoting/proto/event.pb.h" 25 #include "remoting/proto/event.pb.h"
26 #include "testing/gmock/include/gmock/gmock.h" 26 #include "testing/gmock/include/gmock/gmock.h"
27 #include "third_party/webrtc/modules/desktop_capture/desktop_frame.h" 27 #include "third_party/webrtc/modules/desktop_capture/desktop_frame.h"
28 #include "third_party/webrtc/modules/desktop_capture/mouse_cursor_monitor.h" 28 #include "third_party/webrtc/modules/desktop_capture/mouse_cursor_monitor.h"
29 29
30 namespace base { 30 namespace base {
31 class TimeDelta; 31 class TimeDelta;
32 class SingleThreadTaskRunner; 32 class SingleThreadTaskRunner;
33 } // namespace base 33 } // namespace base
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 MOCK_METHOD1(OnClientConnected, void(const std::string& jid)); 148 MOCK_METHOD1(OnClientConnected, void(const std::string& jid));
149 MOCK_METHOD1(OnClientDisconnected, void(const std::string& jid)); 149 MOCK_METHOD1(OnClientDisconnected, void(const std::string& jid));
150 MOCK_METHOD3(OnClientRouteChange, 150 MOCK_METHOD3(OnClientRouteChange,
151 void(const std::string& jid, 151 void(const std::string& jid,
152 const std::string& channel_name, 152 const std::string& channel_name,
153 const protocol::TransportRoute& route)); 153 const protocol::TransportRoute& route));
154 MOCK_METHOD1(OnStart, void(const std::string& xmpp_login)); 154 MOCK_METHOD1(OnStart, void(const std::string& xmpp_login));
155 MOCK_METHOD0(OnShutdown, void()); 155 MOCK_METHOD0(OnShutdown, void());
156 }; 156 };
157 157
158 class MockGnubbyAuthHandler : public GnubbyAuthHandler { 158 class MockSecurityKeyAuthHandler : public SecurityKeyAuthHandler {
159 public: 159 public:
160 MockGnubbyAuthHandler(); 160 MockSecurityKeyAuthHandler();
161 ~MockGnubbyAuthHandler() override; 161 ~MockSecurityKeyAuthHandler() override;
162 162
163 MOCK_METHOD0(CreateGnubbyConnection, void()); 163 MOCK_METHOD0(CreateSecurityKeyConnection, void());
164 MOCK_CONST_METHOD1(IsValidConnectionId, bool(int connection_id)); 164 MOCK_CONST_METHOD1(IsValidConnectionId, bool(int connection_id));
165 MOCK_METHOD2(SendClientResponse, 165 MOCK_METHOD2(SendClientResponse,
166 void(int connection_id, const std::string& response)); 166 void(int connection_id, const std::string& response));
167 MOCK_METHOD1(SendErrorAndCloseConnection, void(int connection_id)); 167 MOCK_METHOD1(SendErrorAndCloseConnection, void(int connection_id));
168 MOCK_CONST_METHOD0(GetActiveConnectionCountForTest, size_t()); 168 MOCK_CONST_METHOD0(GetActiveConnectionCountForTest, size_t());
169 MOCK_METHOD1(SetRequestTimeoutForTest, void(base::TimeDelta timeout)); 169 MOCK_METHOD1(SetRequestTimeoutForTest, void(base::TimeDelta timeout));
170 170
171 void SetSendMessageCallback( 171 void SetSendMessageCallback(
172 const GnubbyAuthHandler::SendMessageCallback& callback) override; 172 const SecurityKeyAuthHandler::SendMessageCallback& callback) override;
173 const GnubbyAuthHandler::SendMessageCallback& GetSendMessageCallback(); 173 const SecurityKeyAuthHandler::SendMessageCallback& GetSendMessageCallback();
174 174
175 private: 175 private:
176 GnubbyAuthHandler::SendMessageCallback callback_; 176 SecurityKeyAuthHandler::SendMessageCallback callback_;
177 177
178 DISALLOW_COPY_AND_ASSIGN(MockGnubbyAuthHandler); 178 DISALLOW_COPY_AND_ASSIGN(MockSecurityKeyAuthHandler);
179 }; 179 };
180 180
181 class MockMouseCursorMonitor : public webrtc::MouseCursorMonitor { 181 class MockMouseCursorMonitor : public webrtc::MouseCursorMonitor {
182 public: 182 public:
183 MockMouseCursorMonitor(); 183 MockMouseCursorMonitor();
184 ~MockMouseCursorMonitor() override; 184 ~MockMouseCursorMonitor() override;
185 185
186 MOCK_METHOD2(Init, void(Callback* callback, Mode mode)); 186 MOCK_METHOD2(Init, void(Callback* callback, Mode mode));
187 MOCK_METHOD0(Capture, void()); 187 MOCK_METHOD0(Capture, void());
188 188
189 private: 189 private:
190 DISALLOW_COPY_AND_ASSIGN(MockMouseCursorMonitor); 190 DISALLOW_COPY_AND_ASSIGN(MockMouseCursorMonitor);
191 }; 191 };
192 192
193 } // namespace remoting 193 } // namespace remoting
194 194
195 #endif // REMOTING_HOST_HOST_MOCK_OBJECTS_H_ 195 #endif // REMOTING_HOST_HOST_MOCK_OBJECTS_H_
OLDNEW
« no previous file with comments | « remoting/host/BUILD.gn ('k') | remoting/host/host_mock_objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698