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

Unified Diff: content/browser/site_instance_impl_unittest.cc

Issue 9645003: Introduce abstractions to allow embedders to test RenderViewHost (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge to head. Created 8 years, 9 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
Index: content/browser/site_instance_impl_unittest.cc
diff --git a/content/browser/site_instance_impl_unittest.cc b/content/browser/site_instance_impl_unittest.cc
index e6adf52b78e824eacfb95116c2f42bceae52d5cc..97e3e98923221c615ac09ca528814b6e6c66ff1e 100644
--- a/content/browser/site_instance_impl_unittest.cc
+++ b/content/browser/site_instance_impl_unittest.cc
@@ -9,6 +9,7 @@
#include "content/browser/browsing_instance.h"
#include "content/browser/child_process_security_policy_impl.h"
#include "content/browser/mock_content_browser_client.h"
+#include "content/browser/renderer_host/mock_render_process_host.h"
#include "content/browser/renderer_host/render_process_host_impl.h"
#include "content/browser/renderer_host/render_view_host_impl.h"
#include "content/browser/renderer_host/test_render_view_host.h"
@@ -189,10 +190,9 @@ class TestSiteInstance : public SiteInstanceImpl {
// Test to ensure no memory leaks for SiteInstance objects.
TEST_F(SiteInstanceTest, SiteInstanceDestructor) {
- // The existence of these factories will cause TabContents to create our test
- // one instead of the real one.
- MockRenderProcessHostFactory rph_factory;
- TestRenderViewHostFactory rvh_factory(&rph_factory);
+ // The existence of this object will cause TabContents to create our
+ // test one instead of the real one.
+ content::RenderViewHostTestEnabler rvh_test_enabler;
int site_delete_counter = 0;
int browsing_delete_counter = 0;
const GURL url("test:foo");

Powered by Google App Engine
This is Rietveld 408576698