OLD | NEW |
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_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BROWSERETEST_H_ | 5 #ifndef CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BROWSERETEST_H_ |
6 #define CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BROWSERETEST_H_ | 6 #define CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BROWSERETEST_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 10 matching lines...) Expand all Loading... |
21 namespace content { | 21 namespace content { |
22 | 22 |
23 class BrowserPluginTest : public RenderViewTest { | 23 class BrowserPluginTest : public RenderViewTest { |
24 public: | 24 public: |
25 BrowserPluginTest(); | 25 BrowserPluginTest(); |
26 virtual ~BrowserPluginTest(); | 26 virtual ~BrowserPluginTest(); |
27 | 27 |
28 virtual void SetUp() OVERRIDE; | 28 virtual void SetUp() OVERRIDE; |
29 virtual void TearDown() OVERRIDE; | 29 virtual void TearDown() OVERRIDE; |
30 MockBrowserPluginManager* browser_plugin_manager() const { | 30 MockBrowserPluginManager* browser_plugin_manager() const { |
31 return browser_plugin_manager_.get(); | 31 return static_cast<MockBrowserPluginManager*>( |
| 32 static_cast<RenderViewImpl*>(view_)->browser_plugin_manager()); |
32 } | 33 } |
33 std::string ExecuteScriptAndReturnString(const std::string& script); | 34 std::string ExecuteScriptAndReturnString(const std::string& script); |
34 int ExecuteScriptAndReturnInt(const std::string& script); | 35 int ExecuteScriptAndReturnInt(const std::string& script); |
35 private: | 36 private: |
36 scoped_ptr<MockBrowserPluginManager> browser_plugin_manager_; | |
37 ContentRendererClient content_renderer_client_; | 37 ContentRendererClient content_renderer_client_; |
38 }; | 38 }; |
39 | 39 |
40 } // namespace content | 40 } // namespace content |
41 | 41 |
42 #endif // CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BROWSERETEST_H_ | 42 #endif // CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BROWSERETEST_H_ |
43 | 43 |
OLD | NEW |