| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 <map> | 5 #include <map> |
| 6 #include <string> | 6 #include <string> |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
| (...skipping 295 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 306 DevicePolicyCrosBrowserTest::SetUp(); | 306 DevicePolicyCrosBrowserTest::SetUp(); |
| 307 } | 307 } |
| 308 | 308 |
| 309 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { | 309 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { |
| 310 DevicePolicyCrosBrowserTest::SetUpCommandLine(command_line); | 310 DevicePolicyCrosBrowserTest::SetUpCommandLine(command_line); |
| 311 command_line->AppendSwitch(chromeos::switches::kLoginManager); | 311 command_line->AppendSwitch(chromeos::switches::kLoginManager); |
| 312 command_line->AppendSwitch(chromeos::switches::kForceLoginManagerInTests); | 312 command_line->AppendSwitch(chromeos::switches::kForceLoginManagerInTests); |
| 313 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile, "user"); | 313 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile, "user"); |
| 314 command_line->AppendSwitchASCII(policy::switches::kDeviceManagementUrl, | 314 command_line->AppendSwitchASCII(policy::switches::kDeviceManagementUrl, |
| 315 test_server_.GetServiceURL().spec()); | 315 test_server_.GetServiceURL().spec()); |
| 316 command_line->AppendSwitch(policy::switches::kEnablePolicyKeyVerification); | |
| 317 } | 316 } |
| 318 | 317 |
| 319 virtual void SetUpInProcessBrowserTestFixture() OVERRIDE { | 318 virtual void SetUpInProcessBrowserTestFixture() OVERRIDE { |
| 320 DevicePolicyCrosBrowserTest::SetUpInProcessBrowserTestFixture(); | 319 DevicePolicyCrosBrowserTest::SetUpInProcessBrowserTestFixture(); |
| 321 | 320 |
| 322 // Clear command-line arguments (but keep command-line switches) so the | 321 // Clear command-line arguments (but keep command-line switches) so the |
| 323 // startup pages policy takes effect. | 322 // startup pages policy takes effect. |
| 324 CommandLine* command_line = CommandLine::ForCurrentProcess(); | 323 CommandLine* command_line = CommandLine::ForCurrentProcess(); |
| 325 CommandLine::StringVector argv(command_line->argv()); | 324 CommandLine::StringVector argv(command_line->argv()); |
| 326 argv.erase(argv.begin() + argv.size() - command_line->GetArgs().size(), | 325 argv.erase(argv.begin() + argv.size() - command_line->GetArgs().size(), |
| (...skipping 846 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1173 if (!IsSessionStarted()) { | 1172 if (!IsSessionStarted()) { |
| 1174 content::WindowedNotificationObserver(chrome::NOTIFICATION_SESSION_STARTED, | 1173 content::WindowedNotificationObserver(chrome::NOTIFICATION_SESSION_STARTED, |
| 1175 base::Bind(IsSessionStarted)).Wait(); | 1174 base::Bind(IsSessionStarted)).Wait(); |
| 1176 } | 1175 } |
| 1177 } | 1176 } |
| 1178 | 1177 |
| 1179 INSTANTIATE_TEST_CASE_P(TermsOfServiceTestInstance, | 1178 INSTANTIATE_TEST_CASE_P(TermsOfServiceTestInstance, |
| 1180 TermsOfServiceTest, testing::Bool()); | 1179 TermsOfServiceTest, testing::Bool()); |
| 1181 | 1180 |
| 1182 } // namespace policy | 1181 } // namespace policy |
| OLD | NEW |