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

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

Issue 667123002: Standardize usage of virtual/override/final in remoting/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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
« no previous file with comments | « remoting/host/daemon_process.h ('k') | remoting/host/desktop_process.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/bind_helpers.h" 6 #include "base/bind_helpers.h"
7 #include "base/location.h" 7 #include "base/location.h"
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/process/process.h" 9 #include "base/process/process.h"
10 #include "ipc/ipc_message.h" 10 #include "ipc/ipc_message.h"
(...skipping 22 matching lines...) Expand all
33 kMessageDisconnectTerminal = ChromotingNetworkHostMsg_DisconnectTerminal::ID, 33 kMessageDisconnectTerminal = ChromotingNetworkHostMsg_DisconnectTerminal::ID,
34 kMessageTerminalDisconnected = 34 kMessageTerminalDisconnected =
35 ChromotingDaemonNetworkMsg_TerminalDisconnected::ID 35 ChromotingDaemonNetworkMsg_TerminalDisconnected::ID
36 }; 36 };
37 37
38 // Provides a public constructor allowing the test to create instances of 38 // Provides a public constructor allowing the test to create instances of
39 // DesktopSession directly. 39 // DesktopSession directly.
40 class FakeDesktopSession : public DesktopSession { 40 class FakeDesktopSession : public DesktopSession {
41 public: 41 public:
42 FakeDesktopSession(DaemonProcess* daemon_process, int id); 42 FakeDesktopSession(DaemonProcess* daemon_process, int id);
43 virtual ~FakeDesktopSession(); 43 ~FakeDesktopSession() override;
44 44
45 virtual void SetScreenResolution( 45 void SetScreenResolution(const ScreenResolution& resolution) override {}
46 const ScreenResolution& resolution) override {}
47 46
48 private: 47 private:
49 DISALLOW_COPY_AND_ASSIGN(FakeDesktopSession); 48 DISALLOW_COPY_AND_ASSIGN(FakeDesktopSession);
50 }; 49 };
51 50
52 class MockDaemonProcess : public DaemonProcess { 51 class MockDaemonProcess : public DaemonProcess {
53 public: 52 public:
54 MockDaemonProcess( 53 MockDaemonProcess(
55 scoped_refptr<AutoThreadTaskRunner> caller_task_runner, 54 scoped_refptr<AutoThreadTaskRunner> caller_task_runner,
56 scoped_refptr<AutoThreadTaskRunner> io_task_runner, 55 scoped_refptr<AutoThreadTaskRunner> io_task_runner,
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
333 EXPECT_EQ(1u, desktop_sessions().size()); 332 EXPECT_EQ(1u, desktop_sessions().size());
334 EXPECT_EQ(id, desktop_sessions().front()->id()); 333 EXPECT_EQ(id, desktop_sessions().front()->id());
335 334
336 EXPECT_TRUE(daemon_process_->OnMessageReceived( 335 EXPECT_TRUE(daemon_process_->OnMessageReceived(
337 ChromotingNetworkHostMsg_ConnectTerminal(id, resolution, false))); 336 ChromotingNetworkHostMsg_ConnectTerminal(id, resolution, false)));
338 EXPECT_TRUE(desktop_sessions().empty()); 337 EXPECT_TRUE(desktop_sessions().empty());
339 EXPECT_EQ(0, terminal_id_); 338 EXPECT_EQ(0, terminal_id_);
340 } 339 }
341 340
342 } // namespace remoting 341 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/host/daemon_process.h ('k') | remoting/host/desktop_process.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698