OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 CHROME_TEST_RENDER_VIEW_TEST_H_ | 5 #ifndef CHROME_TEST_RENDER_VIEW_TEST_H_ |
6 #define CHROME_TEST_RENDER_VIEW_TEST_H_ | 6 #define CHROME_TEST_RENDER_VIEW_TEST_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/command_line.h" | 11 #include "base/command_line.h" |
12 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
13 #include "chrome/renderer/mock_keyboard.h" | 13 #include "chrome/renderer/mock_keyboard.h" |
14 #include "chrome/renderer/mock_render_thread.h" | 14 #include "chrome/renderer/mock_render_thread.h" |
15 #include "chrome/renderer/renderer_main_platform_delegate.h" | 15 #include "chrome/renderer/renderer_main_platform_delegate.h" |
16 #include "content/common/main_function_params.h" | 16 #include "content/common/main_function_params.h" |
17 #include "content/common/native_web_keyboard_event.h" | 17 #include "content/common/native_web_keyboard_event.h" |
18 #include "content/common/sandbox_init_wrapper.h" | 18 #include "content/common/sandbox_init_wrapper.h" |
19 #include "content/renderer/content_renderer_client.h" | 19 #include "content/renderer/content_renderer_client.h" |
20 #include "content/renderer/render_view.h" | 20 #include "content/renderer/render_view.h" |
21 #include "content/renderer/renderer_webkitclient_impl.h" | 21 #include "content/renderer/renderer_webkitclient_impl.h" |
22 #include "testing/gtest/include/gtest/gtest.h" | 22 #include "testing/gtest/include/gtest/gtest.h" |
23 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" | 23 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" |
24 | 24 |
25 namespace autofill { | 25 namespace autofill { |
26 class AutofillAgent; | 26 class AutofillAgent; |
27 class PasswordAutofillManager; | 27 class PasswordAutofillManager; |
28 } | 28 } |
29 class MockRenderProcess; | 29 class MockRenderProcess; |
| 30 class PrintWebViewHelper; |
30 | 31 |
31 class RenderViewTest : public testing::Test { | 32 class RenderViewTest : public testing::Test { |
32 public: | 33 public: |
33 // A special WebKitClientImpl class for getting rid off the dependency to the | 34 // A special WebKitClientImpl class for getting rid off the dependency to the |
34 // sandbox, which is not available in RenderViewTest. | 35 // sandbox, which is not available in RenderViewTest. |
35 class RendererWebKitClientImplNoSandbox : public RendererWebKitClientImpl { | 36 class RendererWebKitClientImplNoSandbox : public RendererWebKitClientImpl { |
36 public: | 37 public: |
37 virtual WebKit::WebSandboxSupport* sandboxSupport() { | 38 virtual WebKit::WebSandboxSupport* sandboxSupport() { |
38 return NULL; | 39 return NULL; |
39 } | 40 } |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 scoped_ptr<MockKeyboard> mock_keyboard_; | 102 scoped_ptr<MockKeyboard> mock_keyboard_; |
102 | 103 |
103 // Used to setup the process so renderers can run. | 104 // Used to setup the process so renderers can run. |
104 scoped_ptr<RendererMainPlatformDelegate> platform_; | 105 scoped_ptr<RendererMainPlatformDelegate> platform_; |
105 scoped_ptr<MainFunctionParams> params_; | 106 scoped_ptr<MainFunctionParams> params_; |
106 scoped_ptr<CommandLine> command_line_; | 107 scoped_ptr<CommandLine> command_line_; |
107 scoped_ptr<SandboxInitWrapper> sandbox_init_wrapper_; | 108 scoped_ptr<SandboxInitWrapper> sandbox_init_wrapper_; |
108 | 109 |
109 autofill::PasswordAutofillManager* password_autofill_; | 110 autofill::PasswordAutofillManager* password_autofill_; |
110 autofill::AutofillAgent* autofill_agent_; | 111 autofill::AutofillAgent* autofill_agent_; |
| 112 PrintWebViewHelper* print_helper_; |
111 }; | 113 }; |
112 | 114 |
113 #endif // CHROME_TEST_RENDER_VIEW_TEST_H_ | 115 #endif // CHROME_TEST_RENDER_VIEW_TEST_H_ |
OLD | NEW |