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

Unified Diff: content/public/test/render_view_test.h

Issue 190663012: Run ContentMain in a browser_test's browser process. This removes duplication of code in the browse… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: cleanup Created 6 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 side-by-side diff with in-line comments
Download patch
Index: content/public/test/render_view_test.h
===================================================================
--- content/public/test/render_view_test.h (revision 257128)
+++ content/public/test/render_view_test.h (working copy)
@@ -13,7 +13,6 @@
#include "base/strings/string16.h"
#include "content/public/browser/native_web_keyboard_event.h"
#include "content/public/common/main_function_params.h"
-#include "content/public/renderer/content_renderer_client.h"
#include "content/public/test/mock_render_thread.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/WebKit/public/platform/Platform.h"
@@ -29,9 +28,13 @@
}
namespace content {
+class ContentBrowserClient;
+class ContentClient;
+class ContentRendererClient;
class MockRenderProcess;
class RendererMainPlatformDelegate;
class RendererWebKitPlatformSupportImplNoSandboxImpl;
+class RenderView;
class RenderViewTest : public testing::Test {
public:
@@ -120,6 +123,12 @@
void SendContentStateImmediately();
blink::WebWidget* GetWebWidget();
+ // Allows a subclass to override the ContentClient and ContentBrowserClient
+ // implementations.
+ virtual ContentClient* CreateContentClient();
+ virtual ContentBrowserClient* CreateContentBrowserClient();
+ virtual ContentRendererClient* CreateContentRendererClient();
+
// testing::Test
virtual void SetUp() OVERRIDE;
@@ -131,7 +140,9 @@
// the embedder's namespace.
RenderView* view_;
RendererWebKitPlatformSupportImplNoSandbox webkit_platform_support_;
- ContentRendererClient content_renderer_client_;
+ scoped_ptr<ContentClient> content_client_;
+ scoped_ptr<ContentBrowserClient> content_browser_client_;
+ scoped_ptr<ContentRendererClient> content_renderer_client_;
scoped_ptr<MockRenderThread> render_thread_;
// Used to setup the process so renderers can run.

Powered by Google App Engine
This is Rietveld 408576698