| OLD | NEW |
| 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 <stddef.h> | 5 #include <stddef.h> |
| 6 #include <stdint.h> | 6 #include <stdint.h> |
| 7 | 7 |
| 8 #include <algorithm> | 8 #include <algorithm> |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 111 #include "components/policy/core/common/policy_types.h" | 111 #include "components/policy/core/common/policy_types.h" |
| 112 #include "components/policy/policy_constants.h" | 112 #include "components/policy/policy_constants.h" |
| 113 #include "components/prefs/pref_service.h" | 113 #include "components/prefs/pref_service.h" |
| 114 #include "components/search/search.h" | 114 #include "components/search/search.h" |
| 115 #include "components/search_engines/template_url.h" | 115 #include "components/search_engines/template_url.h" |
| 116 #include "components/search_engines/template_url_service.h" | 116 #include "components/search_engines/template_url_service.h" |
| 117 #include "components/security_interstitials/core/controller_client.h" | 117 #include "components/security_interstitials/core/controller_client.h" |
| 118 #include "components/strings/grit/components_strings.h" | 118 #include "components/strings/grit/components_strings.h" |
| 119 #include "components/translate/core/browser/language_state.h" | 119 #include "components/translate/core/browser/language_state.h" |
| 120 #include "components/translate/core/browser/translate_infobar_delegate.h" | 120 #include "components/translate/core/browser/translate_infobar_delegate.h" |
| 121 #include "components/update_client/update_client.h" |
| 121 #include "components/update_client/update_client_errors.h" | 122 #include "components/update_client/update_client_errors.h" |
| 122 #include "components/update_client/url_request_post_interceptor.h" | 123 #include "components/update_client/url_request_post_interceptor.h" |
| 123 #include "components/user_prefs/user_prefs.h" | 124 #include "components/user_prefs/user_prefs.h" |
| 124 #include "components/variations/service/variations_service.h" | 125 #include "components/variations/service/variations_service.h" |
| 125 #include "components/version_info/version_info.h" | 126 #include "components/version_info/version_info.h" |
| 126 #include "content/public/browser/browser_context.h" | 127 #include "content/public/browser/browser_context.h" |
| 127 #include "content/public/browser/browser_thread.h" | 128 #include "content/public/browser/browser_thread.h" |
| 128 #include "content/public/browser/child_process_data.h" | 129 #include "content/public/browser/child_process_data.h" |
| 129 #include "content/public/browser/download_item.h" | 130 #include "content/public/browser/download_item.h" |
| 130 #include "content/public/browser/download_manager.h" | 131 #include "content/public/browser/download_manager.h" |
| (...skipping 3487 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3618 } | 3619 } |
| 3619 | 3620 |
| 3620 update_client::CrxComponent ComponentUpdaterPolicyTest::MakeCrxComponent( | 3621 update_client::CrxComponent ComponentUpdaterPolicyTest::MakeCrxComponent( |
| 3621 bool supports_group_policy_enable_component_updates) { | 3622 bool supports_group_policy_enable_component_updates) { |
| 3622 class MockInstaller : public update_client::CrxInstaller { | 3623 class MockInstaller : public update_client::CrxInstaller { |
| 3623 public: | 3624 public: |
| 3624 MockInstaller() {} | 3625 MockInstaller() {} |
| 3625 | 3626 |
| 3626 MOCK_METHOD1(OnUpdateError, void(int error)); | 3627 MOCK_METHOD1(OnUpdateError, void(int error)); |
| 3627 MOCK_METHOD2(Install, | 3628 MOCK_METHOD2(Install, |
| 3628 bool(const base::DictionaryValue& manifest, | 3629 update_client::CrxInstaller::Result( |
| 3629 const base::FilePath& unpack_path)); | 3630 const base::DictionaryValue& manifest, |
| 3631 const base::FilePath& unpack_path)); |
| 3630 MOCK_METHOD2(GetInstalledFile, | 3632 MOCK_METHOD2(GetInstalledFile, |
| 3631 bool(const std::string& file, base::FilePath* installed_file)); | 3633 bool(const std::string& file, base::FilePath* installed_file)); |
| 3632 MOCK_METHOD0(Uninstall, bool()); | 3634 MOCK_METHOD0(Uninstall, bool()); |
| 3633 | 3635 |
| 3634 private: | 3636 private: |
| 3635 ~MockInstaller() override {} | 3637 ~MockInstaller() override {} |
| 3636 }; | 3638 }; |
| 3637 | 3639 |
| 3638 // component id "jebgalgnebhfojomionfpkfelancnnkf". | 3640 // component id "jebgalgnebhfojomionfpkfelancnnkf". |
| 3639 static const uint8_t jebg_hash[] = { | 3641 static const uint8_t jebg_hash[] = { |
| (...skipping 585 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4225 | 4227 |
| 4226 SetEmptyPolicy(); | 4228 SetEmptyPolicy(); |
| 4227 // Policy not set. | 4229 // Policy not set. |
| 4228 CheckSystemTimezoneAutomaticDetectionPolicyUnset(); | 4230 CheckSystemTimezoneAutomaticDetectionPolicyUnset(); |
| 4229 EXPECT_TRUE(CheckResolveTimezoneByGeolocation(true, false)); | 4231 EXPECT_TRUE(CheckResolveTimezoneByGeolocation(true, false)); |
| 4230 EXPECT_TRUE(manager->TimeZoneResolverShouldBeRunningForTests()); | 4232 EXPECT_TRUE(manager->TimeZoneResolverShouldBeRunningForTests()); |
| 4231 } | 4233 } |
| 4232 #endif // defined(OS_CHROMEOS) | 4234 #endif // defined(OS_CHROMEOS) |
| 4233 | 4235 |
| 4234 } // namespace policy | 4236 } // namespace policy |
| OLD | NEW |