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

Unified Diff: content/public/test/mock_download_manager.cc

Issue 319703002: Add mime type information to the download database (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix DownloadUIController_HistoryDownload test failure Created 6 years, 6 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
« no previous file with comments | « content/public/test/mock_download_manager.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/test/mock_download_manager.cc
diff --git a/content/public/test/mock_download_manager.cc b/content/public/test/mock_download_manager.cc
index ef5a9f5e7c16d06ad5d3ce6dc808a95b47f53401..a5d7cf99557ab3cc7a8e8495480626192d70d0f9 100644
--- a/content/public/test/mock_download_manager.cc
+++ b/content/public/test/mock_download_manager.cc
@@ -15,6 +15,8 @@ MockDownloadManager::CreateDownloadItemAdapter::CreateDownloadItemAdapter(
const base::FilePath& target_path,
const std::vector<GURL>& url_chain,
const GURL& referrer_url,
+ const std::string& mime_type,
+ const std::string& original_mime_type,
const base::Time& start_time,
const base::Time& end_time,
const std::string& etag,
@@ -30,6 +32,8 @@ MockDownloadManager::CreateDownloadItemAdapter::CreateDownloadItemAdapter(
target_path(target_path),
url_chain(url_chain),
referrer_url(referrer_url),
+ mime_type(mime_type),
+ original_mime_type(original_mime_type),
start_time(start_time),
end_time(end_time),
received_bytes(received_bytes),
@@ -66,6 +70,8 @@ bool MockDownloadManager::CreateDownloadItemAdapter::operator==(
target_path == rhs.target_path &&
url_chain == rhs.url_chain &&
referrer_url == rhs.referrer_url &&
+ mime_type == rhs.mime_type &&
+ original_mime_type == rhs.original_mime_type &&
start_time == rhs.start_time &&
end_time == rhs.end_time &&
etag == rhs.etag &&
@@ -95,6 +101,8 @@ DownloadItem* MockDownloadManager::CreateDownloadItem(
const base::FilePath& target_path,
const std::vector<GURL>& url_chain,
const GURL& referrer_url,
+ const std::string& mime_type,
+ const std::string& original_mime_type,
const base::Time& start_time,
const base::Time& end_time,
const std::string& etag,
@@ -106,9 +114,10 @@ DownloadItem* MockDownloadManager::CreateDownloadItem(
DownloadInterruptReason interrupt_reason,
bool opened) {
CreateDownloadItemAdapter adapter(
- id, current_path, target_path, url_chain, referrer_url, start_time,
- end_time, etag, last_modified, received_bytes, total_bytes, state,
- danger_type, interrupt_reason, opened);
+ id, current_path, target_path, url_chain, referrer_url, mime_type,
+ original_mime_type, start_time, end_time, etag, last_modified,
+ received_bytes, total_bytes, state, danger_type, interrupt_reason,
+ opened);
return MockCreateDownloadItem(adapter);
}
« no previous file with comments | « content/public/test/mock_download_manager.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698