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 "base/bind.h" | 5 #include "base/bind.h" |
6 #include "base/callback.h" | 6 #include "base/callback.h" |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
10 #include "chrome/browser/browser_process.h" | 10 #include "chrome/browser/browser_process.h" |
11 #include "chrome/browser/prefs/browser_prefs.h" | 11 #include "chrome/browser/prefs/browser_prefs.h" |
12 #include "chrome/browser/prefs/command_line_pref_store.h" | 12 #include "chrome/browser/prefs/command_line_pref_store.h" |
13 #include "chrome/browser/prefs/pref_service_mock_factory.h" | |
14 #include "chrome/browser/prefs/pref_service_syncable.h" | |
15 #include "chrome/common/chrome_switches.h" | 13 #include "chrome/common/chrome_switches.h" |
16 #include "components/policy/core/common/external_data_fetcher.h" | 14 #include "components/policy/core/common/external_data_fetcher.h" |
17 #include "components/policy/core/common/mock_configuration_policy_provider.h" | 15 #include "components/policy/core/common/mock_configuration_policy_provider.h" |
18 #include "components/policy/core/common/policy_map.h" | 16 #include "components/policy/core/common/policy_map.h" |
19 #include "components/policy/core/common/policy_service_impl.h" | 17 #include "components/policy/core/common/policy_service_impl.h" |
20 #include "components/pref_registry/pref_registry_syncable.h" | 18 #include "components/pref_registry/pref_registry_syncable.h" |
21 #include "components/proxy_config/proxy_config_dictionary.h" | 19 #include "components/proxy_config/proxy_config_dictionary.h" |
22 #include "components/proxy_config/proxy_config_pref_names.h" | 20 #include "components/proxy_config/proxy_config_pref_names.h" |
| 21 #include "components/syncable_prefs/pref_service_mock_factory.h" |
| 22 #include "components/syncable_prefs/pref_service_syncable.h" |
23 #include "content/public/test/test_browser_thread_bundle.h" | 23 #include "content/public/test/test_browser_thread_bundle.h" |
24 #include "policy/policy_constants.h" | 24 #include "policy/policy_constants.h" |
25 #include "testing/gtest/include/gtest/gtest.h" | 25 #include "testing/gtest/include/gtest/gtest.h" |
26 | 26 |
27 using ::testing::Return; | 27 using ::testing::Return; |
28 using ::testing::_; | 28 using ::testing::_; |
29 | 29 |
30 namespace policy { | 30 namespace policy { |
31 | 31 |
32 namespace { | 32 namespace { |
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
231 // Try a second time time with the managed PrefStore in place, the | 231 // Try a second time time with the managed PrefStore in place, the |
232 // auto-detect should be overridden. The default pref store must be | 232 // auto-detect should be overridden. The default pref store must be |
233 // in place with the appropriate default value for this to work. | 233 // in place with the appropriate default value for this to work. |
234 prefs = CreatePrefService(true); | 234 prefs = CreatePrefService(true); |
235 ProxyConfigDictionary dict2( | 235 ProxyConfigDictionary dict2( |
236 prefs->GetDictionary(proxy_config::prefs::kProxy)); | 236 prefs->GetDictionary(proxy_config::prefs::kProxy)); |
237 assertProxyModeWithoutParams(dict2, ProxyPrefs::MODE_DIRECT); | 237 assertProxyModeWithoutParams(dict2, ProxyPrefs::MODE_DIRECT); |
238 } | 238 } |
239 | 239 |
240 } // namespace policy | 240 } // namespace policy |
OLD | NEW |