summaryrefslogtreecommitdiffstats
path: root/chrome/browser
diff options
context:
space:
mode:
authorbrettw@google.com <brettw@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-15 18:13:29 +0000
committerbrettw@google.com <brettw@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-15 18:13:29 +0000
commit57acf1f06349b991670c5cf164f1a1e6d520034f (patch)
treeaa4294f7bba517a65e27facf896fde9e922927a4 /chrome/browser
parentb9cf0e2cbfee699155187435c55347dc877c7102 (diff)
downloadchromium_src-57acf1f06349b991670c5cf164f1a1e6d520034f.zip
chromium_src-57acf1f06349b991670c5cf164f1a1e6d520034f.tar.gz
chromium_src-57acf1f06349b991670c5cf164f1a1e6d520034f.tar.bz2
Remove the unneeded pending entry from the unit tests.
Review URL: http://codereview.chromium.org/2859 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2220 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser')
-rw-r--r--chrome/browser/navigation_controller_unittest.cc17
1 files changed, 0 insertions, 17 deletions
diff --git a/chrome/browser/navigation_controller_unittest.cc b/chrome/browser/navigation_controller_unittest.cc
index cfd372b..5f9d85e 100644
--- a/chrome/browser/navigation_controller_unittest.cc
+++ b/chrome/browser/navigation_controller_unittest.cc
@@ -59,7 +59,6 @@ class TestContents : public TabContents {
// want the normal behavior of TabContents just saying it committed since we
// want to behave more like the renderer and call RendererDidNavigate.
virtual bool NavigateToPendingEntry(bool reload) {
- pending_entry_.reset(new NavigationEntry(*controller()->GetPendingEntry()));
return true;
}
@@ -77,14 +76,6 @@ class TestContents : public TabContents {
NavigationController::LoadCommittedDetails details;
controller()->RendererDidNavigate(params, false, &details);
}
-
- NavigationEntry* pending_entry() const { return pending_entry_.get(); }
- void set_pending_entry(NavigationEntry* e) { pending_entry_.reset(e); }
-
- protected:
-
- private:
- scoped_ptr<NavigationEntry> pending_entry_;
};
class TestContentsFactory : public TabContentsFactory {
@@ -342,7 +333,6 @@ TEST_F(NavigationControllerTest, LoadURL) {
EXPECT_EQ(0, notifications.size());
// The load should now be pending.
- EXPECT_TRUE(contents->pending_entry());
EXPECT_EQ(contents->controller()->GetEntryCount(), 0);
EXPECT_EQ(contents->controller()->GetLastCommittedEntryIndex(), -1);
EXPECT_EQ(contents->controller()->GetPendingEntryIndex(), -1);
@@ -372,7 +362,6 @@ TEST_F(NavigationControllerTest, LoadURL) {
contents->controller()->LoadURL(url2, PageTransition::TYPED);
// The load should now be pending.
- EXPECT_TRUE(contents->pending_entry());
EXPECT_EQ(contents->controller()->GetEntryCount(), 1);
EXPECT_EQ(contents->controller()->GetLastCommittedEntryIndex(), 0);
EXPECT_EQ(contents->controller()->GetPendingEntryIndex(), -1);
@@ -598,8 +587,6 @@ TEST_F(NavigationControllerTest, Reload_GeneratesNewPage) {
contents->controller()->Reload();
EXPECT_EQ(0, notifications.size());
- contents->pending_entry()->set_url(url2);
- contents->pending_entry()->set_transition_type(PageTransition::LINK);
contents->CompleteNavigationAsRenderer(1, url2);
EXPECT_TRUE(notifications.Check1AndReset(NOTIFY_NAV_ENTRY_COMMITTED));
@@ -985,10 +972,6 @@ TEST_F(NavigationControllerTest, LinkClick) {
contents->CompleteNavigationAsRenderer(0, url1);
EXPECT_TRUE(notifications.Check1AndReset(NOTIFY_NAV_ENTRY_COMMITTED));
- contents->set_pending_entry(new NavigationEntry(kTestContentsType1, NULL, 0,
- url2,
- std::wstring(),
- PageTransition::LINK));
contents->CompleteNavigationAsRenderer(1, url2);
EXPECT_TRUE(notifications.Check1AndReset(NOTIFY_NAV_ENTRY_COMMITTED));