Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(536)

Side by Side Diff: content/test/test_renderer_host.h

Issue 9702072: Second try for (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/ui/views/frame/browser_view.cc ('k') | ui/aura/test/test_activation_client.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 void NavigateAndCommit(const GURL& url); 142 void NavigateAndCommit(const GURL& url);
143 143
144 // Simulates a reload of the current page. 144 // Simulates a reload of the current page.
145 void Reload(); 145 void Reload();
146 146
147 protected: 147 protected:
148 // testing::Test 148 // testing::Test
149 virtual void SetUp() OVERRIDE; 149 virtual void SetUp() OVERRIDE;
150 virtual void TearDown() OVERRIDE; 150 virtual void TearDown() OVERRIDE;
151 151
152 #if defined(USE_AURA)
153 aura::RootWindow* root_window() const { return root_window_.get(); }
154 #endif
155
152 // Replaces the RPH being used. 156 // Replaces the RPH being used.
153 void SetRenderProcessHostFactory(RenderProcessHostFactory* factory); 157 void SetRenderProcessHostFactory(RenderProcessHostFactory* factory);
154 158
155 // This browser context will be created in SetUp if it has not already been 159 // This browser context will be created in SetUp if it has not already been
156 // created. This allows tests to override the browser context if they so 160 // created. This allows tests to override the browser context if they so
157 // choose in their own SetUp function before calling the base class's (us) 161 // choose in their own SetUp function before calling the base class's (us)
158 // SetUp(). 162 // SetUp().
159 scoped_ptr<BrowserContext> browser_context_; 163 scoped_ptr<BrowserContext> browser_context_;
160 164
161 MessageLoopForUI message_loop_; 165 MessageLoopForUI message_loop_;
162 166
163 private: 167 private:
164 scoped_ptr<TestTabContents> contents_; 168 scoped_ptr<TestTabContents> contents_;
165 #if defined(USE_AURA) 169 #if defined(USE_AURA)
166 scoped_ptr<aura::RootWindow> root_window_; 170 scoped_ptr<aura::RootWindow> root_window_;
167 scoped_ptr<aura::test::TestStackingClient> test_stacking_client_; 171 scoped_ptr<aura::test::TestStackingClient> test_stacking_client_;
168 #endif 172 #endif
169 RenderViewHostTestEnabler rvh_test_enabler_; 173 RenderViewHostTestEnabler rvh_test_enabler_;
170 174
171 DISALLOW_COPY_AND_ASSIGN(RenderViewHostTestHarness); 175 DISALLOW_COPY_AND_ASSIGN(RenderViewHostTestHarness);
172 }; 176 };
173 177
174 } // namespace content 178 } // namespace content
175 179
176 // TODO(joi): Remove this after converting all clients. 180 // TODO(joi): Remove this after converting all clients.
177 using content::RenderViewHostTestHarness; 181 using content::RenderViewHostTestHarness;
178 182
179 #endif // CONTENT_TEST_TEST_RENDERER_HOST_H_ 183 #endif // CONTENT_TEST_TEST_RENDERER_HOST_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/frame/browser_view.cc ('k') | ui/aura/test/test_activation_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698