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

Unified Diff: content/browser/tab_contents/tab_contents_unittest.cc

Issue 9706012: Add abstractions that let embedders drive tests of WebContents. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove CONTENT_EXPORT on statically linked functions. Merge to head for commit. 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/tab_contents/tab_contents_unittest.cc
diff --git a/content/browser/tab_contents/tab_contents_unittest.cc b/content/browser/tab_contents/tab_contents_unittest.cc
index cc4acd7f7900ffc6652f2b0d392e762579fa086d..217bf41b4d8168d2117c94f3566702c40ccff7b9 100644
--- a/content/browser/tab_contents/tab_contents_unittest.cc
+++ b/content/browser/tab_contents/tab_contents_unittest.cc
@@ -279,16 +279,16 @@ class TabContentsTest : public RenderViewHostImplTestHarness {
url_util::AddStandardScheme("tabcontentstest");
old_client_ = content::GetContentClient();
- content::SetContentClient(&client_);
old_browser_client_ = content::GetContentClient()->browser();
+ content::SetContentClient(&client_);
content::GetContentClient()->set_browser(&browser_client_);
- RenderViewHostTestHarness::SetUp();
+ RenderViewHostImplTestHarness::SetUp();
}
virtual void TearDown() {
content::GetContentClient()->set_browser(old_browser_client_);
content::SetContentClient(old_client_);
- RenderViewHostTestHarness::TearDown();
+ RenderViewHostImplTestHarness::TearDown();
}
private:
@@ -1861,7 +1861,8 @@ TEST_F(TabContentsTest, CopyStateFromAndPruneSourceInterstitial) {
// Create another NavigationController.
GURL url3("http://foo2");
- scoped_ptr<TestTabContents> other_contents(CreateTestTabContents());
+ scoped_ptr<TestTabContents> other_contents(
+ static_cast<TestTabContents*>(CreateTestWebContents()));
NavigationControllerImpl& other_controller =
other_contents->GetControllerImpl();
other_contents->NavigateAndCommit(url3);
@@ -1889,7 +1890,8 @@ TEST_F(TabContentsTest, CopyStateFromAndPruneTargetInterstitial) {
contents()->NavigateAndCommit(url1);
// Create another NavigationController.
- scoped_ptr<TestTabContents> other_contents(CreateTestTabContents());
+ scoped_ptr<TestTabContents> other_contents(
+ static_cast<TestTabContents*>(CreateTestWebContents()));
NavigationControllerImpl& other_controller =
other_contents->GetControllerImpl();
« no previous file with comments | « content/browser/tab_contents/render_view_host_manager_unittest.cc ('k') | content/browser/tab_contents/test_tab_contents.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698