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

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

Issue 2529533003: Pass DesktopEnvironmentOptions form network to desktop process. (Closed)
Patch Set: Created 4 years 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
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 "remoting/host/desktop_process.h" 5 #include "remoting/host/desktop_process.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after
279 } 279 }
280 280
281 void DesktopProcessTest::SendCrashRequest() { 281 void DesktopProcessTest::SendCrashRequest() {
282 tracked_objects::Location location = FROM_HERE; 282 tracked_objects::Location location = FROM_HERE;
283 daemon_channel_->Send(new ChromotingDaemonMsg_Crash( 283 daemon_channel_->Send(new ChromotingDaemonMsg_Crash(
284 location.function_name(), location.file_name(), location.line_number())); 284 location.function_name(), location.file_name(), location.line_number()));
285 } 285 }
286 286
287 void DesktopProcessTest::SendStartSessionAgent() { 287 void DesktopProcessTest::SendStartSessionAgent() {
288 network_channel_->Send(new ChromotingNetworkDesktopMsg_StartSessionAgent( 288 network_channel_->Send(new ChromotingNetworkDesktopMsg_StartSessionAgent(
289 "user@domain/rest-of-jid", ScreenResolution(), false)); 289 "user@domain/rest-of-jid", ScreenResolution(),
290 DesktopEnvironmentOptions()));
290 } 291 }
291 292
292 // Launches the desktop process and waits when it connects back. 293 // Launches the desktop process and waits when it connects back.
293 TEST_F(DesktopProcessTest, Basic) { 294 TEST_F(DesktopProcessTest, Basic) {
294 InSequence s; 295 InSequence s;
295 EXPECT_CALL(daemon_listener_, OnChannelConnected(_)); 296 EXPECT_CALL(daemon_listener_, OnChannelConnected(_));
296 EXPECT_CALL(daemon_listener_, OnDesktopAttached(_)) 297 EXPECT_CALL(daemon_listener_, OnDesktopAttached(_))
297 .WillOnce(DoAll( 298 .WillOnce(DoAll(
298 Invoke(this, &DesktopProcessTest::OnDesktopAttached), 299 Invoke(this, &DesktopProcessTest::OnDesktopAttached),
299 InvokeWithoutArgs(this, &DesktopProcessTest::DisconnectChannels))); 300 InvokeWithoutArgs(this, &DesktopProcessTest::DisconnectChannels)));
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
335 } 336 }
336 337
337 // Run the desktop process and ask it to crash. 338 // Run the desktop process and ask it to crash.
338 TEST_F(DesktopProcessTest, DeathTest) { 339 TEST_F(DesktopProcessTest, DeathTest) {
339 testing::GTEST_FLAG(death_test_style) = "threadsafe"; 340 testing::GTEST_FLAG(death_test_style) = "threadsafe";
340 341
341 EXPECT_DEATH(RunDeathTest(), ""); 342 EXPECT_DEATH(RunDeathTest(), "");
342 } 343 }
343 344
344 } // namespace remoting 345 } // namespace remoting
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698