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

Side by Side Diff: remoting/host/chromoting_host_unittest.cc

Issue 10696134: remoting/host: Rename Capturer to VideoFrameCapturer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 | Annotate | Revision Log
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 #include "base/bind.h" 5 #include "base/bind.h"
6 #include "base/memory/scoped_ptr.h" 6 #include "base/memory/scoped_ptr.h"
7 #include "base/message_loop_proxy.h" 7 #include "base/message_loop_proxy.h"
8 #include "remoting/jingle_glue/mock_objects.h" 8 #include "remoting/jingle_glue/mock_objects.h"
9 #include "remoting/host/capturer_fake.h" 9 #include "remoting/host/video_frame_capturer_fake.h"
10 #include "remoting/host/chromoting_host.h" 10 #include "remoting/host/chromoting_host.h"
11 #include "remoting/host/chromoting_host_context.h" 11 #include "remoting/host/chromoting_host_context.h"
12 #include "remoting/host/host_mock_objects.h" 12 #include "remoting/host/host_mock_objects.h"
13 #include "remoting/host/it2me_host_user_interface.h" 13 #include "remoting/host/it2me_host_user_interface.h"
14 #include "remoting/proto/video.pb.h" 14 #include "remoting/proto/video.pb.h"
15 #include "remoting/protocol/errors.h" 15 #include "remoting/protocol/errors.h"
16 #include "remoting/protocol/protocol_mock_objects.h" 16 #include "remoting/protocol/protocol_mock_objects.h"
17 #include "remoting/protocol/session_config.h" 17 #include "remoting/protocol/session_config.h"
18 #include "testing/gmock_mutant.h" 18 #include "testing/gmock_mutant.h"
19 #include "testing/gmock/include/gmock/gmock.h" 19 #include "testing/gmock/include/gmock/gmock.h"
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 EXPECT_CALL(context_, capture_task_runner()) 75 EXPECT_CALL(context_, capture_task_runner())
76 .Times(AnyNumber()) 76 .Times(AnyNumber())
77 .WillRepeatedly(Return(message_loop_proxy_.get())); 77 .WillRepeatedly(Return(message_loop_proxy_.get()));
78 EXPECT_CALL(context_, encode_task_runner()) 78 EXPECT_CALL(context_, encode_task_runner())
79 .Times(AnyNumber()) 79 .Times(AnyNumber())
80 .WillRepeatedly(Return(message_loop_proxy_.get())); 80 .WillRepeatedly(Return(message_loop_proxy_.get()));
81 EXPECT_CALL(context_, network_task_runner()) 81 EXPECT_CALL(context_, network_task_runner())
82 .Times(AnyNumber()) 82 .Times(AnyNumber())
83 .WillRepeatedly(Return(message_loop_proxy_.get())); 83 .WillRepeatedly(Return(message_loop_proxy_.get()));
84 84
85 scoped_ptr<Capturer> capturer(new CapturerFake()); 85 scoped_ptr<VideoFrameCapturer> capturer(new VideoFrameCapturerFake());
86 event_executor_ = new MockEventExecutor(); 86 event_executor_ = new MockEventExecutor();
87 desktop_environment_ = DesktopEnvironment::CreateFake( 87 desktop_environment_ = DesktopEnvironment::CreateFake(
88 &context_, 88 &context_,
89 capturer.Pass(), 89 capturer.Pass(),
90 scoped_ptr<EventExecutor>(event_executor_)); 90 scoped_ptr<EventExecutor>(event_executor_));
91 session_manager_ = new protocol::MockSessionManager(); 91 session_manager_ = new protocol::MockSessionManager();
92 92
93 host_ = new ChromotingHost( 93 host_ = new ChromotingHost(
94 &context_, &signal_strategy_, desktop_environment_.get(), 94 &context_, &signal_strategy_, desktop_environment_.get(),
95 scoped_ptr<protocol::SessionManager>(session_manager_)); 95 scoped_ptr<protocol::SessionManager>(session_manager_));
(...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after
632 ExpectClientDisconnected(0, true, video_packet_sent, 632 ExpectClientDisconnected(0, true, video_packet_sent,
633 InvokeWithoutArgs(this, &ChromotingHostTest::ShutdownHost)); 633 InvokeWithoutArgs(this, &ChromotingHostTest::ShutdownHost));
634 EXPECT_CALL(host_status_observer_, OnShutdown()); 634 EXPECT_CALL(host_status_observer_, OnShutdown());
635 635
636 host_->Start(); 636 host_->Start();
637 SimulateClientConnection(0, true, false); 637 SimulateClientConnection(0, true, false);
638 message_loop_.Run(); 638 message_loop_.Run();
639 } 639 }
640 640
641 } // namespace remoting 641 } // namespace remoting
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698