| OLD | NEW |
| 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 "net/base/ip_endpoint.h" | 8 #include "net/base/ip_endpoint.h" |
| 9 #include "remoting/host/video_frame_capturer.h" | 9 #include "remoting/host/video_frame_capturer.h" |
| 10 #include "remoting/host/chromoting_host_context.h" | 10 #include "remoting/host/chromoting_host_context.h" |
| 11 #include "remoting/host/client_session.h" | 11 #include "remoting/host/client_session.h" |
| 12 #include "remoting/host/continue_window.h" | 12 #include "remoting/host/continue_window.h" |
| 13 #include "remoting/host/desktop_environment.h" |
| 14 #include "remoting/host/desktop_environment_factory.h" |
| 13 #include "remoting/host/disconnect_window.h" | 15 #include "remoting/host/disconnect_window.h" |
| 14 #include "remoting/host/event_executor.h" | 16 #include "remoting/host/event_executor.h" |
| 15 #include "remoting/host/host_status_observer.h" | 17 #include "remoting/host/host_status_observer.h" |
| 16 #include "remoting/host/local_input_monitor.h" | 18 #include "remoting/host/local_input_monitor.h" |
| 17 #include "remoting/host/user_authenticator.h" | 19 #include "remoting/host/user_authenticator.h" |
| 18 #include "testing/gmock/include/gmock/gmock.h" | 20 #include "testing/gmock/include/gmock/gmock.h" |
| 19 | 21 |
| 20 namespace remoting { | 22 namespace remoting { |
| 21 | 23 |
| 22 class MockCaptureCompletedCallback { | 24 class MockCaptureCompletedCallback { |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 ClientSession* client, | 114 ClientSession* client, |
| 113 const std::string& channel_name, | 115 const std::string& channel_name, |
| 114 const protocol::TransportRoute& route)); | 116 const protocol::TransportRoute& route)); |
| 115 MOCK_METHOD2(OnClientDimensionsChanged, void(ClientSession* client, | 117 MOCK_METHOD2(OnClientDimensionsChanged, void(ClientSession* client, |
| 116 const SkISize& size)); | 118 const SkISize& size)); |
| 117 | 119 |
| 118 private: | 120 private: |
| 119 DISALLOW_COPY_AND_ASSIGN(MockClientSessionEventHandler); | 121 DISALLOW_COPY_AND_ASSIGN(MockClientSessionEventHandler); |
| 120 }; | 122 }; |
| 121 | 123 |
| 124 class MockDesktopEnvironmentFactory : public DesktopEnvironmentFactory { |
| 125 public: |
| 126 MockDesktopEnvironmentFactory(); |
| 127 virtual ~MockDesktopEnvironmentFactory(); |
| 128 |
| 129 MOCK_METHOD1(CreatePtr, DesktopEnvironment*(ClientSession* client)); |
| 130 |
| 131 virtual scoped_ptr<DesktopEnvironment> Create(ClientSession* client) OVERRIDE; |
| 132 |
| 133 private: |
| 134 DISALLOW_COPY_AND_ASSIGN(MockDesktopEnvironmentFactory); |
| 135 }; |
| 136 |
| 122 class MockEventExecutor : public EventExecutor { | 137 class MockEventExecutor : public EventExecutor { |
| 123 public: | 138 public: |
| 124 MockEventExecutor(); | 139 MockEventExecutor(); |
| 125 virtual ~MockEventExecutor(); | 140 virtual ~MockEventExecutor(); |
| 126 | 141 |
| 127 MOCK_METHOD1(InjectClipboardEvent, | 142 MOCK_METHOD1(InjectClipboardEvent, |
| 128 void(const protocol::ClipboardEvent& event)); | 143 void(const protocol::ClipboardEvent& event)); |
| 129 MOCK_METHOD1(InjectKeyEvent, void(const protocol::KeyEvent& event)); | 144 MOCK_METHOD1(InjectKeyEvent, void(const protocol::KeyEvent& event)); |
| 130 MOCK_METHOD1(InjectMouseEvent, void(const protocol::MouseEvent& event)); | 145 MOCK_METHOD1(InjectMouseEvent, void(const protocol::MouseEvent& event)); |
| 131 MOCK_METHOD1(StartPtr, | 146 MOCK_METHOD1(StartPtr, |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 164 MOCK_METHOD2(Authenticate, bool(const std::string& username, | 179 MOCK_METHOD2(Authenticate, bool(const std::string& username, |
| 165 const std::string& password)); | 180 const std::string& password)); |
| 166 | 181 |
| 167 private: | 182 private: |
| 168 DISALLOW_COPY_AND_ASSIGN(MockUserAuthenticator); | 183 DISALLOW_COPY_AND_ASSIGN(MockUserAuthenticator); |
| 169 }; | 184 }; |
| 170 | 185 |
| 171 } // namespace remoting | 186 } // namespace remoting |
| 172 | 187 |
| 173 #endif // REMOTING_HOST_HOST_MOCK_OBJECTS_H_ | 188 #endif // REMOTING_HOST_HOST_MOCK_OBJECTS_H_ |
| OLD | NEW |