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 "chrome/browser/extensions/crx_installer.h" | 5 #include "chrome/browser/extensions/crx_installer.h" |
6 | 6 |
7 #include "base/at_exit.h" | 7 #include "base/at_exit.h" |
8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
9 #include "base/strings/utf_string_conversions.h" | 9 #include "base/strings/utf_string_conversions.h" |
10 #include "chrome/browser/download/download_crx_util.h" | 10 #include "chrome/browser/download/download_crx_util.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 #include "chrome/test/base/ui_test_utils.h" | 23 #include "chrome/test/base/ui_test_utils.h" |
24 #include "content/public/browser/browser_thread.h" | 24 #include "content/public/browser/browser_thread.h" |
25 #include "content/public/browser/download_manager.h" | 25 #include "content/public/browser/download_manager.h" |
26 #include "content/public/browser/render_view_host.h" | 26 #include "content/public/browser/render_view_host.h" |
27 #include "content/public/test/browser_test_utils.h" | 27 #include "content/public/test/browser_test_utils.h" |
28 #include "content/public/test/download_test_observer.h" | 28 #include "content/public/test/download_test_observer.h" |
29 #include "content/public/test/test_utils.h" | 29 #include "content/public/test/test_utils.h" |
30 #include "extensions/browser/extension_prefs.h" | 30 #include "extensions/browser/extension_prefs.h" |
31 #include "extensions/browser/extension_registry.h" | 31 #include "extensions/browser/extension_registry.h" |
32 #include "extensions/browser/extension_system.h" | 32 #include "extensions/browser/extension_system.h" |
| 33 #include "extensions/browser/install/crx_installer_error.h" |
33 #include "extensions/browser/management_policy.h" | 34 #include "extensions/browser/management_policy.h" |
34 #include "extensions/browser/notification_types.h" | 35 #include "extensions/browser/notification_types.h" |
35 #include "extensions/common/extension.h" | 36 #include "extensions/common/extension.h" |
36 #include "extensions/common/feature_switch.h" | 37 #include "extensions/common/feature_switch.h" |
37 #include "extensions/common/file_util.h" | 38 #include "extensions/common/file_util.h" |
38 #include "extensions/common/permissions/permission_set.h" | 39 #include "extensions/common/permissions/permission_set.h" |
39 #include "extensions/common/switches.h" | 40 #include "extensions/common/switches.h" |
40 #include "ui/base/l10n/l10n_util.h" | 41 #include "ui/base/l10n/l10n_util.h" |
41 | 42 |
42 #if defined(OS_CHROMEOS) | 43 #if defined(OS_CHROMEOS) |
(...skipping 552 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
595 // because previously withheld permissions are now being requested. | 596 // because previously withheld permissions are now being requested. |
596 enable_scripts_switch.reset(); | 597 enable_scripts_switch.reset(); |
597 extension = InstallExtension(crx_path, -1); | 598 extension = InstallExtension(crx_path, -1); |
598 EXPECT_FALSE(registry->enabled_extensions().GetByID(extension_id)); | 599 EXPECT_FALSE(registry->enabled_extensions().GetByID(extension_id)); |
599 EXPECT_TRUE(registry->disabled_extensions().GetByID(extension_id)); | 600 EXPECT_TRUE(registry->disabled_extensions().GetByID(extension_id)); |
600 EXPECT_TRUE(ExtensionPrefs::Get(browser()->profile())->GetDisableReasons( | 601 EXPECT_TRUE(ExtensionPrefs::Get(browser()->profile())->GetDisableReasons( |
601 extension_id) & Extension::DISABLE_PERMISSIONS_INCREASE); | 602 extension_id) & Extension::DISABLE_PERMISSIONS_INCREASE); |
602 } | 603 } |
603 | 604 |
604 } // namespace extensions | 605 } // namespace extensions |
OLD | NEW |