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 "chrome/browser/extensions/extension_service.h" | 5 #include "chrome/browser/extensions/extension_service.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 #include <algorithm> | 9 #include <algorithm> |
10 #include <map> | 10 #include <map> |
11 #include <set> | 11 #include <set> |
12 #include <string> | 12 #include <string> |
13 #include <utility> | 13 #include <utility> |
14 #include <vector> | 14 #include <vector> |
15 | 15 |
16 #include "base/at_exit.h" | 16 #include "base/at_exit.h" |
17 #include "base/bind.h" | 17 #include "base/bind.h" |
18 #include "base/command_line.h" | 18 #include "base/command_line.h" |
19 #include "base/files/file_enumerator.h" | 19 #include "base/files/file_enumerator.h" |
20 #include "base/files/file_util.h" | 20 #include "base/files/file_util.h" |
21 #include "base/files/scoped_temp_dir.h" | 21 #include "base/files/scoped_temp_dir.h" |
22 #include "base/json/json_file_value_serializer.h" | 22 #include "base/json/json_file_value_serializer.h" |
23 #include "base/json/json_reader.h" | 23 #include "base/json/json_reader.h" |
24 #include "base/json/json_string_value_serializer.h" | 24 #include "base/json/json_string_value_serializer.h" |
25 #include "base/location.h" | 25 #include "base/location.h" |
26 #include "base/macros.h" | 26 #include "base/macros.h" |
27 #include "base/memory/scoped_ptr.h" | 27 #include "base/memory/scoped_ptr.h" |
28 #include "base/memory/weak_ptr.h" | 28 #include "base/memory/weak_ptr.h" |
29 #include "base/prefs/scoped_user_pref_update.h" | |
30 #include "base/single_thread_task_runner.h" | 29 #include "base/single_thread_task_runner.h" |
31 #include "base/stl_util.h" | 30 #include "base/stl_util.h" |
32 #include "base/strings/pattern.h" | 31 #include "base/strings/pattern.h" |
33 #include "base/strings/string16.h" | 32 #include "base/strings/string16.h" |
34 #include "base/strings/string_number_conversions.h" | 33 #include "base/strings/string_number_conversions.h" |
35 #include "base/strings/string_util.h" | 34 #include "base/strings/string_util.h" |
36 #include "base/strings/utf_string_conversions.h" | 35 #include "base/strings/utf_string_conversions.h" |
37 #include "base/thread_task_runner_handle.h" | 36 #include "base/thread_task_runner_handle.h" |
38 #include "base/version.h" | 37 #include "base/version.h" |
39 #include "build/build_config.h" | 38 #include "build/build_config.h" |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 #include "chrome/common/chrome_switches.h" | 73 #include "chrome/common/chrome_switches.h" |
75 #include "chrome/common/extensions/api/plugins/plugins_handler.h" | 74 #include "chrome/common/extensions/api/plugins/plugins_handler.h" |
76 #include "chrome/common/extensions/manifest_handlers/app_launch_info.h" | 75 #include "chrome/common/extensions/manifest_handlers/app_launch_info.h" |
77 #include "chrome/common/extensions/manifest_handlers/content_scripts_handler.h" | 76 #include "chrome/common/extensions/manifest_handlers/content_scripts_handler.h" |
78 #include "chrome/common/pref_names.h" | 77 #include "chrome/common/pref_names.h" |
79 #include "chrome/common/url_constants.h" | 78 #include "chrome/common/url_constants.h" |
80 #include "chrome/test/base/scoped_browser_locale.h" | 79 #include "chrome/test/base/scoped_browser_locale.h" |
81 #include "chrome/test/base/testing_profile.h" | 80 #include "chrome/test/base/testing_profile.h" |
82 #include "components/crx_file/id_util.h" | 81 #include "components/crx_file/id_util.h" |
83 #include "components/pref_registry/pref_registry_syncable.h" | 82 #include "components/pref_registry/pref_registry_syncable.h" |
| 83 #include "components/prefs/scoped_user_pref_update.h" |
84 #include "components/syncable_prefs/pref_service_syncable.h" | 84 #include "components/syncable_prefs/pref_service_syncable.h" |
85 #include "components/syncable_prefs/testing_pref_service_syncable.h" | 85 #include "components/syncable_prefs/testing_pref_service_syncable.h" |
86 #include "content/public/browser/dom_storage_context.h" | 86 #include "content/public/browser/dom_storage_context.h" |
87 #include "content/public/browser/gpu_data_manager.h" | 87 #include "content/public/browser/gpu_data_manager.h" |
88 #include "content/public/browser/indexed_db_context.h" | 88 #include "content/public/browser/indexed_db_context.h" |
89 #include "content/public/browser/notification_service.h" | 89 #include "content/public/browser/notification_service.h" |
90 #include "content/public/browser/plugin_service.h" | 90 #include "content/public/browser/plugin_service.h" |
91 #include "content/public/browser/render_process_host.h" | 91 #include "content/public/browser/render_process_host.h" |
92 #include "content/public/browser/storage_partition.h" | 92 #include "content/public/browser/storage_partition.h" |
93 #include "content/public/common/content_constants.h" | 93 #include "content/public/common/content_constants.h" |
(...skipping 6181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6275 | 6275 |
6276 service()->Observe(chrome::NOTIFICATION_PROFILE_DESTRUCTION_STARTED, | 6276 service()->Observe(chrome::NOTIFICATION_PROFILE_DESTRUCTION_STARTED, |
6277 content::Source<Profile>(profile()), | 6277 content::Source<Profile>(profile()), |
6278 content::NotificationService::NoDetails()); | 6278 content::NotificationService::NoDetails()); |
6279 EXPECT_EQ(UnloadedExtensionInfo::REASON_PROFILE_SHUTDOWN, unloaded_reason_); | 6279 EXPECT_EQ(UnloadedExtensionInfo::REASON_PROFILE_SHUTDOWN, unloaded_reason_); |
6280 EXPECT_EQ(0u, registry()->enabled_extensions().size()); | 6280 EXPECT_EQ(0u, registry()->enabled_extensions().size()); |
6281 EXPECT_EQ(0u, registry()->disabled_extensions().size()); | 6281 EXPECT_EQ(0u, registry()->disabled_extensions().size()); |
6282 EXPECT_EQ(0u, registry()->terminated_extensions().size()); | 6282 EXPECT_EQ(0u, registry()->terminated_extensions().size()); |
6283 EXPECT_EQ(0u, registry()->blacklisted_extensions().size()); | 6283 EXPECT_EQ(0u, registry()->blacklisted_extensions().size()); |
6284 } | 6284 } |
OLD | NEW |