| 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 "apps/app_window_registry.h" | 8 #include "apps/app_window_registry.h" |
| 9 #include "apps/ui/native_app_window.h" | 9 #include "apps/ui/native_app_window.h" |
| 10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 #include "chrome/browser/chromeos/extensions/device_local_account_external_polic
y_loader.h" | 38 #include "chrome/browser/chromeos/extensions/device_local_account_external_polic
y_loader.h" |
| 39 #include "chrome/browser/chromeos/extensions/external_cache.h" | 39 #include "chrome/browser/chromeos/extensions/external_cache.h" |
| 40 #include "chrome/browser/chromeos/login/existing_user_controller.h" | 40 #include "chrome/browser/chromeos/login/existing_user_controller.h" |
| 41 #include "chrome/browser/chromeos/login/screens/wizard_screen.h" | 41 #include "chrome/browser/chromeos/login/screens/wizard_screen.h" |
| 42 #include "chrome/browser/chromeos/login/ui/login_display_host.h" | 42 #include "chrome/browser/chromeos/login/ui/login_display_host.h" |
| 43 #include "chrome/browser/chromeos/login/ui/login_display_host_impl.h" | 43 #include "chrome/browser/chromeos/login/ui/login_display_host_impl.h" |
| 44 #include "chrome/browser/chromeos/login/ui/webui_login_view.h" | 44 #include "chrome/browser/chromeos/login/ui/webui_login_view.h" |
| 45 #include "chrome/browser/chromeos/login/users/avatar/user_image_manager.h" | 45 #include "chrome/browser/chromeos/login/users/avatar/user_image_manager.h" |
| 46 #include "chrome/browser/chromeos/login/users/avatar/user_image_manager_impl.h" | 46 #include "chrome/browser/chromeos/login/users/avatar/user_image_manager_impl.h" |
| 47 #include "chrome/browser/chromeos/login/users/avatar/user_image_manager_test_uti
l.h" | 47 #include "chrome/browser/chromeos/login/users/avatar/user_image_manager_test_uti
l.h" |
| 48 #include "chrome/browser/chromeos/login/users/chrome_user_manager.h" |
| 48 #include "chrome/browser/chromeos/login/users/user_manager.h" | 49 #include "chrome/browser/chromeos/login/users/user_manager.h" |
| 49 #include "chrome/browser/chromeos/login/users/user_manager_impl.h" | |
| 50 #include "chrome/browser/chromeos/login/wizard_controller.h" | 50 #include "chrome/browser/chromeos/login/wizard_controller.h" |
| 51 #include "chrome/browser/chromeos/policy/browser_policy_connector_chromeos.h" | 51 #include "chrome/browser/chromeos/policy/browser_policy_connector_chromeos.h" |
| 52 #include "chrome/browser/chromeos/policy/cloud_external_data_manager_base_test_u
til.h" | 52 #include "chrome/browser/chromeos/policy/cloud_external_data_manager_base_test_u
til.h" |
| 53 #include "chrome/browser/chromeos/policy/device_local_account.h" | 53 #include "chrome/browser/chromeos/policy/device_local_account.h" |
| 54 #include "chrome/browser/chromeos/policy/device_local_account_policy_service.h" | 54 #include "chrome/browser/chromeos/policy/device_local_account_policy_service.h" |
| 55 #include "chrome/browser/chromeos/policy/device_policy_builder.h" | 55 #include "chrome/browser/chromeos/policy/device_policy_builder.h" |
| 56 #include "chrome/browser/chromeos/policy/device_policy_cros_browser_test.h" | 56 #include "chrome/browser/chromeos/policy/device_policy_cros_browser_test.h" |
| 57 #include "chrome/browser/chromeos/policy/proto/chrome_device_policy.pb.h" | 57 #include "chrome/browser/chromeos/policy/proto/chrome_device_policy.pb.h" |
| 58 #include "chrome/browser/extensions/crx_installer.h" | 58 #include "chrome/browser/extensions/crx_installer.h" |
| 59 #include "chrome/browser/extensions/extension_service.h" | 59 #include "chrome/browser/extensions/extension_service.h" |
| (...skipping 767 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 827 ASSERT_TRUE(cache); | 827 ASSERT_TRUE(cache); |
| 828 EXPECT_FALSE(cache->GetExtension(kGoodExtensionID, NULL, NULL)); | 828 EXPECT_FALSE(cache->GetExtension(kGoodExtensionID, NULL, NULL)); |
| 829 } | 829 } |
| 830 | 830 |
| 831 IN_PROC_BROWSER_TEST_F(DeviceLocalAccountTest, ExternalData) { | 831 IN_PROC_BROWSER_TEST_F(DeviceLocalAccountTest, ExternalData) { |
| 832 // chromeos::UserManager requests an external data fetch whenever | 832 // chromeos::UserManager requests an external data fetch whenever |
| 833 // the key::kUserAvatarImage policy is set. Since this test wants to | 833 // the key::kUserAvatarImage policy is set. Since this test wants to |
| 834 // verify that the underlying policy subsystem will start a fetch | 834 // verify that the underlying policy subsystem will start a fetch |
| 835 // without this request as well, the chromeos::UserManager must be | 835 // without this request as well, the chromeos::UserManager must be |
| 836 // prevented from seeing the policy change. | 836 // prevented from seeing the policy change. |
| 837 reinterpret_cast<chromeos::UserManagerImpl*>(chromeos::UserManager::Get())-> | 837 reinterpret_cast<chromeos::ChromeUserManager*>(chromeos::UserManager::Get()) |
| 838 StopPolicyObserverForTesting(); | 838 ->StopPolicyObserverForTesting(); |
| 839 | 839 |
| 840 UploadDeviceLocalAccountPolicy(); | 840 UploadDeviceLocalAccountPolicy(); |
| 841 AddPublicSessionToDevicePolicy(kAccountId1); | 841 AddPublicSessionToDevicePolicy(kAccountId1); |
| 842 | 842 |
| 843 WaitForPolicy(); | 843 WaitForPolicy(); |
| 844 | 844 |
| 845 // Start serving external data at |kExternalDataURL|. | 845 // Start serving external data at |kExternalDataURL|. |
| 846 scoped_ptr<base::RunLoop> run_loop(new base::RunLoop); | 846 scoped_ptr<base::RunLoop> run_loop(new base::RunLoop); |
| 847 scoped_ptr<net::FakeURLFetcherFactory> fetcher_factory( | 847 scoped_ptr<net::FakeURLFetcherFactory> fetcher_factory( |
| 848 new net::FakeURLFetcherFactory( | 848 new net::FakeURLFetcherFactory( |
| (...skipping 576 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1425 ASSERT_TRUE(content::ExecuteScript(contents, | 1425 ASSERT_TRUE(content::ExecuteScript(contents, |
| 1426 "$('tos-accept-button').click();")); | 1426 "$('tos-accept-button').click();")); |
| 1427 | 1427 |
| 1428 WaitForSessionStart(); | 1428 WaitForSessionStart(); |
| 1429 } | 1429 } |
| 1430 | 1430 |
| 1431 INSTANTIATE_TEST_CASE_P(TermsOfServiceDownloadTestInstance, | 1431 INSTANTIATE_TEST_CASE_P(TermsOfServiceDownloadTestInstance, |
| 1432 TermsOfServiceDownloadTest, testing::Bool()); | 1432 TermsOfServiceDownloadTest, testing::Bool()); |
| 1433 | 1433 |
| 1434 } // namespace policy | 1434 } // namespace policy |
| OLD | NEW |