OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #ifndef CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_BROWSERTEST_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_BROWSERTEST_H_ |
6 #define CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_BROWSERTEST_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_BROWSERTEST_H_ |
7 | 7 |
8 #include "chrome/browser/extensions/extension_test_notification_observer.h" | 8 #include "chrome/browser/extensions/extension_test_notification_observer.h" |
9 #include "chrome/test/base/web_ui_browser_test.h" | 9 #include "chrome/test/base/web_ui_browser_test.h" |
10 #include "extensions/browser/test_management_policy.h" | 10 #include "extensions/browser/test_management_policy.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 Profile* GetProfile(); | 23 Profile* GetProfile(); |
24 | 24 |
25 const std::string& last_loaded_extension_id() { | 25 const std::string& last_loaded_extension_id() { |
26 return observer_->last_loaded_extension_id(); | 26 return observer_->last_loaded_extension_id(); |
27 } | 27 } |
28 | 28 |
29 void SetUpOnMainThread() override; | 29 void SetUpOnMainThread() override; |
30 | 30 |
31 void InstallGoodExtension(); | 31 void InstallGoodExtension(); |
32 | 32 |
| 33 void InstallErrorsExtension(); |
| 34 |
33 void AddManagedPolicyProvider(); | 35 void AddManagedPolicyProvider(); |
34 | 36 |
35 private: | 37 private: |
36 bool WaitForExtensionViewsToLoad(); | 38 bool WaitForExtensionViewsToLoad(); |
37 const extensions::Extension* LoadUnpackedExtension( | 39 void InstallUnpackedExtension(const base::FilePath& path); |
38 const base::FilePath& path); | |
39 const extensions::Extension* InstallExtension(const base::FilePath& path); | 40 const extensions::Extension* InstallExtension(const base::FilePath& path); |
40 | 41 |
41 scoped_ptr<ExtensionTestNotificationObserver> observer_; | 42 scoped_ptr<ExtensionTestNotificationObserver> observer_; |
42 | 43 |
43 // The default profile to be used. | 44 // The default profile to be used. |
44 Profile* profile_; | 45 Profile* profile_; |
45 | 46 |
46 // Used to simulate managed extensions (by being registered as a provider). | 47 // Used to simulate managed extensions (by being registered as a provider). |
47 extensions::TestManagementPolicyProvider policy_provider_; | 48 extensions::TestManagementPolicyProvider policy_provider_; |
48 | 49 |
49 DISALLOW_COPY_AND_ASSIGN(ExtensionSettingsUIBrowserTest); | 50 DISALLOW_COPY_AND_ASSIGN(ExtensionSettingsUIBrowserTest); |
50 }; | 51 }; |
51 | 52 |
52 #endif // CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_BROWSERTEST_H_ | 53 #endif // CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_BROWSERTEST_H_ |
OLD | NEW |