Index: remoting/host/chromoting_host_unittest.cc |
diff --git a/remoting/host/chromoting_host_unittest.cc b/remoting/host/chromoting_host_unittest.cc |
index 185be7138170c339981a3a6c9ccb3c2d018e56b8..f04be7c2a6d5038a29bc64b36bc843ce42a8bf88 100644 |
--- a/remoting/host/chromoting_host_unittest.cc |
+++ b/remoting/host/chromoting_host_unittest.cc |
@@ -88,10 +88,12 @@ class ChromotingHostTest : public testing::Test { |
EXPECT_CALL(context_, ui_message_loop()) |
.Times(AnyNumber()); |
- Capturer* capturer = new CapturerFake(); |
+ scoped_ptr<Capturer> capturer(new CapturerFake()); |
event_executor_ = new MockEventExecutor(); |
- desktop_environment_.reset( |
- new DesktopEnvironment(&context_, capturer, event_executor_)); |
+ desktop_environment_ = DesktopEnvironment::CreateFake( |
+ &context_, |
+ capturer.Pass(), |
+ scoped_ptr<protocol::InputStub>(event_executor_)); |
host_ = new ChromotingHost( |
&context_, &signal_strategy_, desktop_environment_.get(), |