Content settings: remove some plugin-related code/resources when... there are no...
[chromium-blink-merge.git] / content / public / test / content_browser_test.h
blob91bd0dfbc9f30c339e9e6ac9b653c5219dbca13e
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
3 // found in the LICENSE file.
5 #ifndef CONTENT_PUBLIC_TEST_CONTENT_BROWSER_TEST_H_
6 #define CONTENT_PUBLIC_TEST_CONTENT_BROWSER_TEST_H_
8 #include "base/memory/scoped_ptr.h"
9 #include "content/public/test/browser_test.h"
10 #include "content/public/test/browser_test_base.h"
12 namespace content {
13 class Shell;
14 class ShellMainDelegate;
16 // Base class for browser tests which use content_shell.
17 class ContentBrowserTest : public BrowserTestBase {
18 protected:
19 ContentBrowserTest();
20 ~ContentBrowserTest() override;
22 // testing::Test:
23 void SetUp() override;
24 void TearDown() override;
26 // BrowserTestBase:
27 void RunTestOnMainThreadLoop() override;
29 protected:
30 // Creates a new window and loads about:blank.
31 Shell* CreateBrowser();
33 // Creates an off-the-record window and loads about:blank.
34 Shell* CreateOffTheRecordBrowser();
36 // Returns the window for the test.
37 Shell* shell() const { return shell_; }
39 private:
40 Shell* shell_;
42 #if defined(OS_ANDROID)
43 // For all other platforms, this is done automatically when calling into
44 // ContentMain. For Android we set things up manually.
45 scoped_ptr<ShellMainDelegate> shell_main_delegate_;
46 #endif
49 } // namespace content
51 #endif // CONTENT_PUBLIC_TEST_CONTENT_BROWSER_TEST_H_