Index: remoting/host/host_mock_objects.h |
diff --git a/remoting/host/host_mock_objects.h b/remoting/host/host_mock_objects.h |
index 569b32489e2e9b24f3eaed5fd5f26d3bec89a8ce..f32066c586cd19db6df23bd9f5810821fc1e1523 100644 |
--- a/remoting/host/host_mock_objects.h |
+++ b/remoting/host/host_mock_objects.h |
@@ -14,6 +14,7 @@ |
#include "remoting/host/disconnect_window.h" |
#include "remoting/host/event_executor.h" |
#include "remoting/host/local_input_monitor.h" |
+#include "remoting/host/session_manager_factory.h" |
#include "remoting/host/user_authenticator.h" |
#include "testing/gmock/include/gmock/gmock.h" |
@@ -135,6 +136,27 @@ class MockEventExecutor : public EventExecutor { |
DISALLOW_COPY_AND_ASSIGN(MockEventExecutor); |
}; |
+class MockSessionManagerFactory : public SessionManagerFactory { |
+ public: |
+ MockSessionManagerFactory(); |
+ virtual ~MockSessionManagerFactory(); |
+ |
+ MOCK_METHOD2(MakeSessionManagerPtr, protocol::SessionManager*( |
+ const NetworkSettings& network_settings, |
+ const scoped_refptr<net::URLRequestContextGetter>& |
+ url_request_context_getter)); |
+ scoped_ptr<protocol::SessionManager> MakeSessionManager( |
+ const NetworkSettings& network_settings, |
+ const scoped_refptr<net::URLRequestContextGetter>& |
+ url_request_context_getter) { |
+ return scoped_ptr<protocol::SessionManager>(MakeSessionManagerPtr( |
+ network_settings, url_request_context_getter)); |
Wez
2012/06/11 22:17:06
Although it seems a bit pointless, I think this be
simonmorris
2012/06/11 23:08:59
This way is consistent with protocol_mock_objects.
|
+ } |
+ |
+ private: |
+ DISALLOW_COPY_AND_ASSIGN(MockSessionManagerFactory); |
+}; |
+ |
class MockUserAuthenticator : public UserAuthenticator { |
public: |
MockUserAuthenticator(); |