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

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

Issue 2705283003: Added last_access_time to DownloadItem and History DB (Closed)
Patch Set: rebase origin/master Created 3 years, 10 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/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 d13298fda7d2d7b08cc045077987eac5fe947efc..ede7691de5c1bcefbf8e6d4bf69f875cbf9f9899 100644
--- a/content/browser/download/download_manager_impl_unittest.cc
+++ b/content/browser/download/download_manager_impl_unittest.cc
@@ -139,8 +139,8 @@ class MockDownloadItemFactory
const GURL& tab_referrer_url,
const std::string& mime_type,
const std::string& original_mime_type,
- const base::Time& start_time,
- const base::Time& end_time,
+ base::Time start_time,
+ base::Time end_time,
const std::string& etag,
const std::string& last_modofied,
int64_t received_bytes,
@@ -150,6 +150,7 @@ class MockDownloadItemFactory
DownloadDangerType danger_type,
DownloadInterruptReason interrupt_reason,
bool opened,
+ base::Time last_access_time,
const std::vector<DownloadItem::ReceivedSlice>& received_slices,
const net::NetLogWithSource& net_log) override;
DownloadItemImpl* CreateActiveItem(
@@ -212,8 +213,8 @@ DownloadItemImpl* MockDownloadItemFactory::CreatePersistedItem(
const GURL& tab_referrer_url,
const std::string& mime_type,
const std::string& original_mime_type,
- const base::Time& start_time,
- const base::Time& end_time,
+ base::Time start_time,
+ base::Time end_time,
const std::string& etag,
const std::string& last_modified,
int64_t received_bytes,
@@ -223,6 +224,7 @@ DownloadItemImpl* MockDownloadItemFactory::CreatePersistedItem(
DownloadDangerType danger_type,
DownloadInterruptReason interrupt_reason,
bool opened,
+ base::Time last_access_time,
const std::vector<DownloadItem::ReceivedSlice>& received_slices,
const net::NetLogWithSource& net_log) {
DCHECK(items_.find(download_id) == items_.end());
@@ -607,7 +609,7 @@ TEST_F(DownloadManagerTest, GetDownloadByGuid) {
"application/octet-stream", "application/octet-stream", base::Time::Now(),
base::Time::Now(), std::string(), std::string(), 10, 10, std::string(),
DownloadItem::INTERRUPTED, DOWNLOAD_DANGER_TYPE_NOT_DANGEROUS,
- DOWNLOAD_INTERRUPT_REASON_SERVER_FAILED, false,
+ DOWNLOAD_INTERRUPT_REASON_SERVER_FAILED, false, base::Time::Now(),
std::vector<DownloadItem::ReceivedSlice>());
ASSERT_TRUE(persisted_item);
« no previous file with comments | « content/browser/download/download_manager_impl.cc ('k') | content/browser/download/mock_download_item_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698