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 CONTENT_TEST_TEST_RENDERER_HOST_H_ | 5 #ifndef CONTENT_TEST_TEST_RENDERER_HOST_H_ |
6 #define CONTENT_TEST_TEST_RENDERER_HOST_H_ | 6 #define CONTENT_TEST_TEST_RENDERER_HOST_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 virtual ~RenderViewHostTestHarness(); | 120 virtual ~RenderViewHostTestHarness(); |
121 | 121 |
122 NavigationController& controller(); | 122 NavigationController& controller(); |
123 virtual WebContents* web_contents(); | 123 virtual WebContents* web_contents(); |
124 RenderViewHost* rvh(); | 124 RenderViewHost* rvh(); |
125 RenderViewHost* pending_rvh(); | 125 RenderViewHost* pending_rvh(); |
126 RenderViewHost* active_rvh(); | 126 RenderViewHost* active_rvh(); |
127 BrowserContext* browser_context(); | 127 BrowserContext* browser_context(); |
128 MockRenderProcessHost* process(); | 128 MockRenderProcessHost* process(); |
129 | 129 |
130 // Frees the current tab contents for tests that want to test destruction. | 130 // Frees the current WebContents for tests that want to test destruction. |
131 void DeleteContents(); | 131 void DeleteContents(); |
132 | 132 |
133 // Sets the current tab contents for tests that want to alter it. Takes | 133 // Sets the current WebContents for tests that want to alter it. Takes |
134 // ownership of the WebContents passed. | 134 // ownership of the WebContents passed. |
135 virtual void SetContents(WebContents* contents); | 135 virtual void SetContents(WebContents* contents); |
136 | 136 |
137 // Creates a new test-enabled WebContents. Ownership passes to the | 137 // Creates a new test-enabled WebContents. Ownership passes to the |
138 // caller. | 138 // caller. |
139 WebContents* CreateTestWebContents(); | 139 WebContents* CreateTestWebContents(); |
140 | 140 |
141 // Cover for |contents()->NavigateAndCommit(url)|. See | 141 // Cover for |contents()->NavigateAndCommit(url)|. See |
142 // WebContentsTester::NavigateAndCommit for details. | 142 // WebContentsTester::NavigateAndCommit for details. |
143 void NavigateAndCommit(const GURL& url); | 143 void NavigateAndCommit(const GURL& url); |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
175 scoped_ptr<aura::test::TestStackingClient> test_stacking_client_; | 175 scoped_ptr<aura::test::TestStackingClient> test_stacking_client_; |
176 #endif | 176 #endif |
177 RenderViewHostTestEnabler rvh_test_enabler_; | 177 RenderViewHostTestEnabler rvh_test_enabler_; |
178 | 178 |
179 DISALLOW_COPY_AND_ASSIGN(RenderViewHostTestHarness); | 179 DISALLOW_COPY_AND_ASSIGN(RenderViewHostTestHarness); |
180 }; | 180 }; |
181 | 181 |
182 } // namespace content | 182 } // namespace content |
183 | 183 |
184 #endif // CONTENT_TEST_TEST_RENDERER_HOST_H_ | 184 #endif // CONTENT_TEST_TEST_RENDERER_HOST_H_ |
OLD | NEW |