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 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_BROWSERTEST_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_BROWSERTEST_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_BROWSERTEST_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_BROWSERTEST_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
11 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
12 #include "base/file_path.h" | 12 #include "base/file_path.h" |
13 #include "base/scoped_temp_dir.h" | 13 #include "base/files/scoped_temp_dir.h" |
14 #include "chrome/browser/extensions/extension_host.h" | 14 #include "chrome/browser/extensions/extension_host.h" |
15 #include "chrome/common/extensions/extension.h" | 15 #include "chrome/common/extensions/extension.h" |
| 16 #include "chrome/common/extensions/feature_switch.h" |
16 #include "chrome/common/extensions/features/feature.h" | 17 #include "chrome/common/extensions/features/feature.h" |
17 #include "chrome/common/extensions/feature_switch.h" | |
18 #include "chrome/test/base/in_process_browser_test.h" | 18 #include "chrome/test/base/in_process_browser_test.h" |
19 #include "content/public/browser/notification_details.h" | 19 #include "content/public/browser/notification_details.h" |
20 #include "content/public/browser/notification_observer.h" | 20 #include "content/public/browser/notification_observer.h" |
21 #include "content/public/browser/notification_types.h" | 21 #include "content/public/browser/notification_types.h" |
22 #include "content/public/browser/web_contents.h" | 22 #include "content/public/browser/web_contents.h" |
23 | 23 |
24 class ExtensionProcessManager; | 24 class ExtensionProcessManager; |
25 | 25 |
26 // Base class for extension browser tests. Provides utilities for loading, | 26 // Base class for extension browser tests. Provides utilities for loading, |
27 // unloading, and installing extensions. | 27 // unloading, and installing extensions. |
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
197 | 197 |
198 // test_data/extensions. | 198 // test_data/extensions. |
199 FilePath test_data_dir_; | 199 FilePath test_data_dir_; |
200 std::string last_loaded_extension_id_; | 200 std::string last_loaded_extension_id_; |
201 int extension_installs_observed_; | 201 int extension_installs_observed_; |
202 int extension_load_errors_observed_; | 202 int extension_load_errors_observed_; |
203 int crx_installers_done_observed_; | 203 int crx_installers_done_observed_; |
204 | 204 |
205 private: | 205 private: |
206 // Temporary directory for testing. | 206 // Temporary directory for testing. |
207 ScopedTempDir temp_dir_; | 207 base::ScopedTempDir temp_dir_; |
208 | 208 |
209 // Specifies the type of UI (if any) to show during installation and what | 209 // Specifies the type of UI (if any) to show during installation and what |
210 // user action to simulate. | 210 // user action to simulate. |
211 enum InstallUIType { | 211 enum InstallUIType { |
212 INSTALL_UI_TYPE_NONE, | 212 INSTALL_UI_TYPE_NONE, |
213 INSTALL_UI_TYPE_CANCEL, | 213 INSTALL_UI_TYPE_CANCEL, |
214 INSTALL_UI_TYPE_NORMAL, | 214 INSTALL_UI_TYPE_NORMAL, |
215 INSTALL_UI_TYPE_AUTO_CONFIRM, | 215 INSTALL_UI_TYPE_AUTO_CONFIRM, |
216 }; | 216 }; |
217 | 217 |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
256 // Disable external install UI. | 256 // Disable external install UI. |
257 extensions::FeatureSwitch::ScopedOverride | 257 extensions::FeatureSwitch::ScopedOverride |
258 override_prompt_for_external_extensions_; | 258 override_prompt_for_external_extensions_; |
259 | 259 |
260 // Disable the sideload wipeout UI. | 260 // Disable the sideload wipeout UI. |
261 extensions::FeatureSwitch::ScopedOverride | 261 extensions::FeatureSwitch::ScopedOverride |
262 override_sideload_wipeout_; | 262 override_sideload_wipeout_; |
263 }; | 263 }; |
264 | 264 |
265 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_BROWSERTEST_H_ | 265 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_BROWSERTEST_H_ |
OLD | NEW |