| Index: content/public/test/render_view_test.h
|
| diff --git a/content/public/test/render_view_test.h b/content/public/test/render_view_test.h
|
| index 27cea17e7b33dee013de0c7fe5db01754d7283cd..6e351de7ebd0a0cda3659b224504ecd4af965847 100644
|
| --- a/content/public/test/render_view_test.h
|
| +++ b/content/public/test/render_view_test.h
|
| @@ -48,23 +48,23 @@ class FakeCompositorDependencies;
|
| class MockRenderProcess;
|
| class PageState;
|
| class RendererMainPlatformDelegate;
|
| -class RendererBlinkPlatformImplNoSandboxImpl;
|
| +class RendererBlinkPlatformImplTestOverrideImpl;
|
| class RenderView;
|
|
|
| class RenderViewTest : public testing::Test, blink::WebLeakDetectorClient {
|
| public:
|
| - // A special BlinkPlatformImpl class for getting rid off the dependency to the
|
| - // sandbox, which is not available in RenderViewTest.
|
| - class RendererBlinkPlatformImplNoSandbox {
|
| + // A special BlinkPlatformImpl class with overrides that are useful for
|
| + // RenderViewTest.
|
| + class RendererBlinkPlatformImplTestOverride {
|
| public:
|
| - RendererBlinkPlatformImplNoSandbox();
|
| - ~RendererBlinkPlatformImplNoSandbox();
|
| + RendererBlinkPlatformImplTestOverride();
|
| + ~RendererBlinkPlatformImplTestOverride();
|
| blink::Platform* Get() const;
|
| void Shutdown();
|
|
|
| private:
|
| scoped_ptr<scheduler::RendererScheduler> renderer_scheduler_;
|
| - scoped_ptr<RendererBlinkPlatformImplNoSandboxImpl> blink_platform_impl_;
|
| + scoped_ptr<RendererBlinkPlatformImplTestOverrideImpl> blink_platform_impl_;
|
| };
|
|
|
| RenderViewTest();
|
| @@ -88,10 +88,16 @@ class RenderViewTest : public testing::Test, blink::WebLeakDetectorClient {
|
| bool ExecuteJavaScriptAndReturnIntValue(const base::string16& script,
|
| int* result);
|
|
|
| - // Loads the given HTML into the main frame as a data: URL and blocks until
|
| - // the navigation is committed.
|
| + // Loads |html| into the main frame as a data: URL and blocks until the
|
| + // navigation is committed.
|
| void LoadHTML(const char* html);
|
|
|
| + // Pretends to load |url| into the main frame, but substitutes |html| for the
|
| + // response body (and does not include any response headers). This can be used
|
| + // instead of LoadHTML for tests that cannot use a data: url (for example if
|
| + // document.location needs to be set to something specific.)
|
| + void LoadHTMLWithUrlOverride(const char* html, const char* url);
|
| +
|
| // Returns the current PageState.
|
| // In OOPIF enabled modes, this returns a PageState object for the main frame.
|
| PageState GetCurrentPageState();
|
| @@ -188,7 +194,7 @@ class RenderViewTest : public testing::Test, blink::WebLeakDetectorClient {
|
| // We use a naked pointer because we don't want to expose RenderViewImpl in
|
| // the embedder's namespace.
|
| RenderView* view_;
|
| - RendererBlinkPlatformImplNoSandbox blink_platform_impl_;
|
| + RendererBlinkPlatformImplTestOverride blink_platform_impl_;
|
| scoped_ptr<ContentClient> content_client_;
|
| scoped_ptr<ContentBrowserClient> content_browser_client_;
|
| scoped_ptr<ContentRendererClient> content_renderer_client_;
|
|
|