| Index: remoting/protocol/mock_objects.h
|
| diff --git a/remoting/protocol/mock_objects.h b/remoting/protocol/mock_objects.h
|
| index 045a414255023a5e5356bedccd5121bce6a97c82..99826c28f840a82d978486121a545209c14c1b93 100644
|
| --- a/remoting/protocol/mock_objects.h
|
| +++ b/remoting/protocol/mock_objects.h
|
| @@ -6,9 +6,11 @@
|
| #define REMOTING_PROTOCOL_MOCK_OBJECTS_H_
|
|
|
| #include "remoting/proto/internal.pb.h"
|
| +#include "remoting/protocol/client_stub.h"
|
| #include "remoting/protocol/connection_to_client.h"
|
| #include "remoting/protocol/host_stub.h"
|
| #include "remoting/protocol/input_stub.h"
|
| +#include "remoting/protocol/session.h"
|
| #include "remoting/protocol/video_stub.h"
|
| #include "testing/gmock/include/gmock/gmock.h"
|
|
|
| @@ -21,8 +23,10 @@ class MockConnectionToClient : public ConnectionToClient {
|
| public:
|
| MockConnectionToClient() {}
|
|
|
| - MOCK_METHOD1(Init, void(ChromotocolConnection* connection));
|
| + MOCK_METHOD1(Init, void(Session* session));
|
| MOCK_METHOD0(video_stub, VideoStub*());
|
| + MOCK_METHOD0(client_stub, ClientStub*());
|
| + MOCK_METHOD0(session, Session*());
|
| MOCK_METHOD0(Disconnect, void());
|
|
|
| private:
|
| @@ -78,6 +82,31 @@ class MockVideoStub : public VideoStub {
|
| DISALLOW_COPY_AND_ASSIGN(MockVideoStub);
|
| };
|
|
|
| +class MockSession : public Session {
|
| + public:
|
| + MockSession() {}
|
| +
|
| + MOCK_METHOD1(SetStateChangeCallback, void(StateChangeCallback* callback));
|
| + MOCK_METHOD0(control_channel, net::Socket*());
|
| + MOCK_METHOD0(event_channel, net::Socket*());
|
| + MOCK_METHOD0(video_channel, net::Socket*());
|
| + MOCK_METHOD0(video_rtp_channel, net::Socket*());
|
| + MOCK_METHOD0(video_rtcp_channel, net::Socket*());
|
| + MOCK_METHOD0(jid, const std::string&());
|
| + MOCK_METHOD0(message_loop, MessageLoop*());
|
| + MOCK_METHOD0(candidate_config, const CandidateSessionConfig*());
|
| + MOCK_METHOD0(config, const SessionConfig*());
|
| + MOCK_METHOD1(set_config, void(const SessionConfig* config));
|
| + MOCK_METHOD0(initiator_token, const std::string&());
|
| + MOCK_METHOD1(set_initiator_token, void(const std::string& initiator_token));
|
| + MOCK_METHOD0(receiver_token, const std::string&());
|
| + MOCK_METHOD1(set_receiver_token, void(const std::string& receiver_token));
|
| + MOCK_METHOD1(Close, void(Task* closed_task));
|
| +
|
| + private:
|
| + DISALLOW_COPY_AND_ASSIGN(MockSession);
|
| +};
|
| +
|
| } // namespace protocol
|
| } // namespace remoting
|
|
|
|
|