Disable view source for Developer Tools.
[chromium-blink-merge.git] / chrome / browser / ui / webui / extensions / extension_settings_browsertest.h
blobdcbead3d7da11f3ece166c51a97e17785f7c7096
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
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_BROWSERTEST_H_
6 #define CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_BROWSERTEST_H_
8 #include "chrome/browser/extensions/extension_test_notification_observer.h"
9 #include "chrome/test/base/web_ui_browsertest.h"
10 #include "extensions/common/extension.h"
12 class Profile;
14 // C++ test fixture used by extension_settings_browsertest.js.
15 class ExtensionSettingsUIBrowserTest : public WebUIBrowserTest {
16 public:
17 ExtensionSettingsUIBrowserTest();
18 virtual ~ExtensionSettingsUIBrowserTest();
20 protected:
21 // Get the profile to use.
22 Profile* GetProfile();
24 const std::string& last_loaded_extension_id() {
25 return observer_->last_loaded_extension_id();
28 virtual void SetUpOnMainThread() OVERRIDE;
30 void InstallGoodExtension();
32 private:
33 bool WaitForExtensionViewsToLoad();
34 const extensions::Extension* LoadUnpackedExtension(
35 const base::FilePath& path);
36 const extensions::Extension* InstallExtension(const base::FilePath& path);
38 scoped_ptr<ExtensionTestNotificationObserver> observer_;
40 // The default profile to be used.
41 Profile* profile_;
43 DISALLOW_COPY_AND_ASSIGN(ExtensionSettingsUIBrowserTest);
46 #endif // CHROME_BROWSER_UI_WEBUI_EXTENSIONS_EXTENSION_SETTINGS_BROWSERTEST_H_