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

Unified Diff: remoting/host/screen_recorder_unittest.cc

Issue 8476018: Move ConnectionToClient::EventHandler from ChromotingHost to ClientSession (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: - Created 9 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: remoting/host/screen_recorder_unittest.cc
diff --git a/remoting/host/screen_recorder_unittest.cc b/remoting/host/screen_recorder_unittest.cc
index 3a20283993f902e0644c802d17ba16a7d1d05dbc..254d3741b4d6b4cc1335469d2505c1b5bea0c6aa 100644
--- a/remoting/host/screen_recorder_unittest.cc
+++ b/remoting/host/screen_recorder_unittest.cc
@@ -17,6 +17,7 @@
using ::remoting::protocol::MockConnectionToClient;
using ::remoting::protocol::MockConnectionToClientEventHandler;
using ::remoting::protocol::MockHostStub;
+using ::remoting::protocol::MockSession;
using ::remoting::protocol::MockVideoStub;
using ::testing::_;
@@ -77,8 +78,11 @@ class ScreenRecorderTest : public testing::Test {
// Capturer and Encoder are owned by ScreenRecorder.
encoder_ = new MockEncoder();
+ session_ = new MockSession();
+ EXPECT_CALL(*session_, SetStateChangeCallback(_));
connection_ = new MockConnectionToClient(
- &handler_, &host_stub_, &event_executor_);
+ session_, &host_stub_, &event_executor_);
+ connection_->SetEventHandler(&handler_);
record_ = new ScreenRecorder(
&message_loop_, &message_loop_,
@@ -92,6 +96,7 @@ class ScreenRecorderTest : public testing::Test {
MockConnectionToClientEventHandler handler_;
MockHostStub host_stub_;
MockEventExecutor event_executor_;
+ MockSession* session_; // Owned by |connection_|.
scoped_refptr<MockConnectionToClient> connection_;
// The following mock objects are owned by ScreenRecorder.

Powered by Google App Engine
This is Rietveld 408576698