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

Side by Side Diff: remoting/test/chromoting_test_driver.cc

Issue 1164143002: Added new driver for chromoting. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed unused headers. Clarified comments. Reorganized .gyp file content. Created 5 years, 6 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
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 #include <string>
joedow 2015/06/08 17:20:04 add newline between comment and include statement.
5
6 #include "base/command_line.h"
7 #include "base/test/test_suite.h"
8 #include "base/test/test_switches.h"
9 #include "testing/gtest/include/gtest/gtest.h"
10
11 namespace switches {
12 const char kSingleProcessTestsSwitchName[] = "single-process-tests";
13 const char kUserNameSwitchName[] = "username";
14 }
15
16 int main(int argc, char* argv[]) {
17 testing::InitGoogleTest(&argc, argv);
18 base::TestSuite test_suite(argc, argv);
19
20 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
21 DCHECK(command_line);
22
23 // Do not retry if tests fails.
24 command_line->AppendSwitchASCII(switches::kTestLauncherRetryLimit, "0");
25
26 // Do not run tests in parallel. Interactions between the host and test
27 // client should not interfere with another test client.
joedow 2015/06/08 17:20:04 Can you reword this comment to describe the constr
28 command_line->AppendSwitch(switches::kSingleProcessTestsSwitchName);
29
30 std::string username(
31 command_line->GetSwitchValueASCII(switches::kUserNameSwitchName));
32 // Verify that the username is passed in as an argument.
33 if (username.empty()) {
34 LOG(ERROR) << "No username passed in, can't authenticate without that!";
35 return -1;
36 } else {
joedow 2015/06/08 17:20:04 no need for an else clause here.
37 DVLOG(1) << "Running chromoting tests as: " << username;
38 }
39
40 return 0;
41 }
42
OLDNEW
« remoting/remoting_all.gyp ('K') | « remoting/remoting_test_driver_common.gyp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698