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

Unified Diff: content/browser/download/download_manager_impl_unittest.cc

Issue 11640007: Make the UI an observer of downloads. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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/download/download_manager_impl_unittest.cc
diff --git a/content/browser/download/download_manager_impl_unittest.cc b/content/browser/download/download_manager_impl_unittest.cc
index bc1d9e3239f6adfcc997127e4d4e20c0dfc57bc9..30352d81666dd642ad74f080c3c7f71387b6c5de 100644
--- a/content/browser/download/download_manager_impl_unittest.cc
+++ b/content/browser/download/download_manager_impl_unittest.cc
@@ -180,7 +180,6 @@ class MockDownloadManagerDelegate : public DownloadManagerDelegate {
MOCK_METHOD2(DetermineDownloadTarget,
bool(DownloadItem* item,
const DownloadTargetCallback&));
- MOCK_METHOD0(GetAlternativeWebContentsToNotifyForDownload, WebContents*());
MOCK_METHOD1(ShouldOpenFileBasedOnExtension, bool(const FilePath&));
MOCK_METHOD2(ShouldCompleteDownload,
bool(DownloadItem*, const base::Closure&));
@@ -547,21 +546,6 @@ class DownloadManagerTest : public testing::Test {
base::Unretained(this)));
}
- void AddItemToHistory(MockDownloadItemImpl& item, int64 db_handle) {
- // For DCHECK in AddDownloadItemToHistory. Don't want to use
- // WillRepeatedly as it may have to return true after this.
- if (DCHECK_IS_ON())
- // Null out ShowDownloadInBrowser
- EXPECT_CALL(item, GetWebContents())
- .WillOnce(Return(static_cast<WebContents*>(NULL)));
- EXPECT_CALL(GetMockDownloadManagerDelegate(),
- GetAlternativeWebContentsToNotifyForDownload())
- .WillOnce(Return(static_cast<WebContents*>(NULL)));
-
- EXPECT_CALL(item, IsInProgress())
- .WillOnce(Return(true));
- }
-
protected:
// Key test variable; we'll keep it available to sub-classes.
scoped_refptr<DownloadManagerImpl> download_manager_;

Powered by Google App Engine
This is Rietveld 408576698