summaryrefslogtreecommitdiffstats
path: root/ui/views/test
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-04 14:46:57 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-04 14:46:57 +0000
commitc14ad56370693394f52cf7ddd701c3a92cbb21fd (patch)
tree03034c8f0c526161d4ffe8654b6e5629936ea3f7 /ui/views/test
parentb1e3f20a987493e568ec36fdae0b1bebb816833e (diff)
downloadchromium_src-c14ad56370693394f52cf7ddd701c3a92cbb21fd.zip
chromium_src-c14ad56370693394f52cf7ddd701c3a92cbb21fd.tar.gz
chromium_src-c14ad56370693394f52cf7ddd701c3a92cbb21fd.tar.bz2
Hide TestRenderViewHostFactory from embedders since it depends on internal content classes. Expose a method to allow the WebViewTestHelper to enable the creation of test RenderViewHosts.
BUG=98716 Review URL: https://chromiumcodereview.appspot.com/10510005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@140288 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/views/test')
-rw-r--r--ui/views/test/webview_test_helper.cc6
-rw-r--r--ui/views/test/webview_test_helper.h5
2 files changed, 1 insertions, 10 deletions
diff --git a/ui/views/test/webview_test_helper.cc b/ui/views/test/webview_test_helper.cc
index 5e4b8f3..26d379f 100644
--- a/ui/views/test/webview_test_helper.cc
+++ b/ui/views/test/webview_test_helper.cc
@@ -5,10 +5,8 @@
#include "ui/views/test/webview_test_helper.h"
#include "base/message_loop.h"
-#include "content/public/test/mock_render_process_host.h"
#include "content/public/test/test_browser_thread.h"
#include "content/public/test/test_content_client_initializer.h"
-#include "content/test/test_render_view_host_factory.h"
#include "ui/views/controls/webview/webview.h"
namespace views {
@@ -20,9 +18,7 @@ WebViewTestHelper::WebViewTestHelper(MessageLoopForUI* ui_loop) {
// Setup to register a new RenderViewHost factory which manufactures
// mock render process hosts. This ensures that we never create a 'real'
// render view host since support for it doesn't exist in unit tests.
- rph_factory_.reset(new content::MockRenderProcessHostFactory());
- rvh_factory_.reset(
- new content::TestRenderViewHostFactory(rph_factory_.get()));
+ test_content_client_initializer_->CreateTestRenderViewHosts();
ui_thread_.reset(
new content::TestBrowserThread(content::BrowserThread::UI, ui_loop));
diff --git a/ui/views/test/webview_test_helper.h b/ui/views/test/webview_test_helper.h
index 9868bcc..a6fe1d7 100644
--- a/ui/views/test/webview_test_helper.h
+++ b/ui/views/test/webview_test_helper.h
@@ -13,8 +13,6 @@ class MessageLoopForUI;
namespace content {
class TestContentClientInitializer;
class TestBrowserThread;
-class MockRenderProcessHostFactory;
-class TestRenderViewHostFactory;
} // namespace content
namespace views {
@@ -30,9 +28,6 @@ class WebViewTestHelper {
scoped_ptr<content::TestBrowserThread> ui_thread_;
- scoped_ptr<content::MockRenderProcessHostFactory> rph_factory_;
- scoped_ptr<content::TestRenderViewHostFactory> rvh_factory_;
-
DISALLOW_COPY_AND_ASSIGN(WebViewTestHelper);
};