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

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

Issue 10497013: Move render_view_test.h header from content\test to content\public\test. This way we can enforce th… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix mac Created 8 years, 7 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
« no previous file with comments | « content/content_tests.gypi ('k') | content/renderer/external_popup_menu_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/test/render_view_test.h
===================================================================
--- content/public/test/render_view_test.h (revision 140246)
+++ content/public/test/render_view_test.h (working copy)
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef CONTENT_TEST_RENDER_VIEW_TEST_H_
-#define CONTENT_TEST_RENDER_VIEW_TEST_H_
+#ifndef CONTENT_PUBLIC_TEST_RENDER_VIEW_TEST_H_
+#define CONTENT_PUBLIC_TEST_RENDER_VIEW_TEST_H_
#pragma once
#include <string>
@@ -14,10 +14,8 @@
#include "base/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 "content/renderer/mock_content_renderer_client.h"
-#include "content/renderer/renderer_webkitplatformsupport_impl.h"
-#include "content/test/mock_keyboard.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h"
@@ -26,29 +24,31 @@
namespace WebKit {
class WebHistoryItem;
+class WebKitPlatformSupport;
class WebWidget;
}
-namespace content {
-class RenderView;
-}
-
namespace gfx {
class Rect;
}
namespace content {
+class RendererWebKitPlatformSupportImplNoSandboxImpl;
+
class RenderViewTest : public testing::Test {
public:
// A special WebKitPlatformSupportImpl class for getting rid off the
// dependency to the sandbox, which is not available in RenderViewTest.
- class RendererWebKitPlatformSupportImplNoSandbox :
- public RendererWebKitPlatformSupportImpl {
+ class RendererWebKitPlatformSupportImplNoSandbox {
public:
- virtual WebKit::WebSandboxSupport* sandboxSupport() {
- return NULL;
- }
+ RendererWebKitPlatformSupportImplNoSandbox();
+ ~RendererWebKitPlatformSupportImplNoSandbox();
+ WebKit::WebKitPlatformSupport* Get();
+
+ private:
+ scoped_ptr<RendererWebKitPlatformSupportImplNoSandboxImpl>
+ webkit_platform_support_;
};
RenderViewTest();
@@ -81,12 +81,6 @@
void GoBack(const WebKit::WebHistoryItem& item);
void GoForward(const WebKit::WebHistoryItem& item);
- // Sends IPC messages that emulates a key-press event.
- int SendKeyEvent(MockKeyboard::Layout layout,
- int key_code,
- MockKeyboard::Modifiers key_modifiers,
- string16* output);
-
// Sends one native key event over IPC.
void SendNativeKeyEvent(const content::NativeWebKeyboardEvent& key_event);
@@ -134,8 +128,7 @@
// the embedder's namespace.
content::RenderView* view_;
RendererWebKitPlatformSupportImplNoSandbox webkit_platform_support_;
- MockContentRendererClient mock_content_renderer_client_;
- scoped_ptr<MockKeyboard> mock_keyboard_;
+ ContentRendererClient content_renderer_client_;
scoped_ptr<MockRenderThread> render_thread_;
// Used to setup the process so renderers can run.
@@ -149,4 +142,4 @@
} // namespace content
-#endif // CONTENT_TEST_RENDER_VIEW_TEST_H_
+#endif // CONTENT_PUBLIC_TEST_RENDER_VIEW_TEST_H_
« no previous file with comments | « content/content_tests.gypi ('k') | content/renderer/external_popup_menu_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698