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

Side by Side Diff: chrome/browser/chromeos/policy/device_local_account_browsertest.cc

Issue 131023004: Moved the --device-management-url switch to the policy component. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@BPC-1-split
Patch Set: rebase Created 6 years, 11 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
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 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 #include "chrome/browser/ui/browser.h" 64 #include "chrome/browser/ui/browser.h"
65 #include "chrome/browser/ui/browser_commands.h" 65 #include "chrome/browser/ui/browser_commands.h"
66 #include "chrome/browser/ui/browser_finder.h" 66 #include "chrome/browser/ui/browser_finder.h"
67 #include "chrome/browser/ui/browser_list.h" 67 #include "chrome/browser/ui/browser_list.h"
68 #include "chrome/browser/ui/browser_window.h" 68 #include "chrome/browser/ui/browser_window.h"
69 #include "chrome/browser/ui/host_desktop.h" 69 #include "chrome/browser/ui/host_desktop.h"
70 #include "chrome/browser/ui/tabs/tab_strip_model.h" 70 #include "chrome/browser/ui/tabs/tab_strip_model.h"
71 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" 71 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h"
72 #include "chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h" 72 #include "chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h"
73 #include "chrome/common/chrome_paths.h" 73 #include "chrome/common/chrome_paths.h"
74 #include "chrome/common/chrome_switches.h"
75 #include "chromeos/chromeos_paths.h" 74 #include "chromeos/chromeos_paths.h"
76 #include "chromeos/chromeos_switches.h" 75 #include "chromeos/chromeos_switches.h"
77 #include "chromeos/dbus/fake_session_manager_client.h" 76 #include "chromeos/dbus/fake_session_manager_client.h"
78 #include "components/policy/core/common/cloud/cloud_policy_constants.h" 77 #include "components/policy/core/common/cloud/cloud_policy_constants.h"
79 #include "components/policy/core/common/cloud/cloud_policy_core.h" 78 #include "components/policy/core/common/cloud/cloud_policy_core.h"
80 #include "components/policy/core/common/cloud/cloud_policy_store.h" 79 #include "components/policy/core/common/cloud/cloud_policy_store.h"
81 #include "components/policy/core/common/cloud/policy_builder.h" 80 #include "components/policy/core/common/cloud/policy_builder.h"
82 #include "components/policy/core/common/external_data_fetcher.h" 81 #include "components/policy/core/common/external_data_fetcher.h"
83 #include "components/policy/core/common/policy_map.h" 82 #include "components/policy/core/common/policy_map.h"
84 #include "components/policy/core/common/policy_namespace.h" 83 #include "components/policy/core/common/policy_namespace.h"
85 #include "components/policy/core/common/policy_service.h" 84 #include "components/policy/core/common/policy_service.h"
85 #include "components/policy/core/common/policy_switches.h"
86 #include "content/public/browser/notification_details.h" 86 #include "content/public/browser/notification_details.h"
87 #include "content/public/browser/notification_source.h" 87 #include "content/public/browser/notification_source.h"
88 #include "content/public/browser/web_contents.h" 88 #include "content/public/browser/web_contents.h"
89 #include "content/public/browser/web_ui.h" 89 #include "content/public/browser/web_ui.h"
90 #include "content/public/test/browser_test_utils.h" 90 #include "content/public/test/browser_test_utils.h"
91 #include "content/public/test/test_utils.h" 91 #include "content/public/test/test_utils.h"
92 #include "crypto/rsa_private_key.h" 92 #include "crypto/rsa_private_key.h"
93 #include "extensions/common/extension.h" 93 #include "extensions/common/extension.h"
94 #include "grit/chromium_strings.h" 94 #include "grit/chromium_strings.h"
95 #include "grit/generated_resources.h" 95 #include "grit/generated_resources.h"
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after
301 chromeos::DIR_DEVICE_LOCAL_ACCOUNT_EXTERNAL_DATA, 301 chromeos::DIR_DEVICE_LOCAL_ACCOUNT_EXTERNAL_DATA,
302 external_data_cache_dir_.path())); 302 external_data_cache_dir_.path()));
303 DevicePolicyCrosBrowserTest::SetUp(); 303 DevicePolicyCrosBrowserTest::SetUp();
304 } 304 }
305 305
306 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { 306 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE {
307 DevicePolicyCrosBrowserTest::SetUpCommandLine(command_line); 307 DevicePolicyCrosBrowserTest::SetUpCommandLine(command_line);
308 command_line->AppendSwitch(chromeos::switches::kLoginManager); 308 command_line->AppendSwitch(chromeos::switches::kLoginManager);
309 command_line->AppendSwitch(chromeos::switches::kForceLoginManagerInTests); 309 command_line->AppendSwitch(chromeos::switches::kForceLoginManagerInTests);
310 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile, "user"); 310 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile, "user");
311 command_line->AppendSwitchASCII( 311 command_line->AppendSwitchASCII(policy::switches::kDeviceManagementUrl,
312 switches::kDeviceManagementUrl, test_server_.GetServiceURL().spec()); 312 test_server_.GetServiceURL().spec());
313 } 313 }
314 314
315 virtual void SetUpInProcessBrowserTestFixture() OVERRIDE { 315 virtual void SetUpInProcessBrowserTestFixture() OVERRIDE {
316 DevicePolicyCrosBrowserTest::SetUpInProcessBrowserTestFixture(); 316 DevicePolicyCrosBrowserTest::SetUpInProcessBrowserTestFixture();
317 317
318 // Clear command-line arguments (but keep command-line switches) so the 318 // Clear command-line arguments (but keep command-line switches) so the
319 // startup pages policy takes effect. 319 // startup pages policy takes effect.
320 CommandLine* command_line = CommandLine::ForCurrentProcess(); 320 CommandLine* command_line = CommandLine::ForCurrentProcess();
321 CommandLine::StringVector argv(command_line->argv()); 321 CommandLine::StringVector argv(command_line->argv());
322 argv.erase(argv.begin() + argv.size() - command_line->GetArgs().size(), 322 argv.erase(argv.begin() + argv.size() - command_line->GetArgs().size(),
(...skipping 865 matching lines...) Expand 10 before | Expand all | Expand 10 after
1188 if (!IsSessionStarted()) { 1188 if (!IsSessionStarted()) {
1189 content::WindowedNotificationObserver(chrome::NOTIFICATION_SESSION_STARTED, 1189 content::WindowedNotificationObserver(chrome::NOTIFICATION_SESSION_STARTED,
1190 base::Bind(IsSessionStarted)).Wait(); 1190 base::Bind(IsSessionStarted)).Wait();
1191 } 1191 }
1192 } 1192 }
1193 1193
1194 INSTANTIATE_TEST_CASE_P(TermsOfServiceTestInstance, 1194 INSTANTIATE_TEST_CASE_P(TermsOfServiceTestInstance,
1195 TermsOfServiceTest, testing::Bool()); 1195 TermsOfServiceTest, testing::Bool());
1196 1196
1197 } // namespace policy 1197 } // namespace policy
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/login/login_utils_browsertest.cc ('k') | chrome/browser/policy/chrome_browser_policy_connector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698