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

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

Issue 2799333002: Clear the received slices in DownloadItemImpl when etag changed. (Closed)
Patch Set: Address the uma issue. Created 3 years, 8 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/browser/download/mock_download_file.h ('k') | content/public/test/test_file_error_injector.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/download/mock_download_file.cc
diff --git a/content/browser/download/mock_download_file.cc b/content/browser/download/mock_download_file.cc
index 2f10f54cf6f3a35ee3bf6e4437415b5c54925870..36282d51b4dcb7c20a5f80cbaf6721661670067a 100644
--- a/content/browser/download/mock_download_file.cc
+++ b/content/browser/download/mock_download_file.cc
@@ -11,7 +11,8 @@ using ::testing::Return;
namespace content {
namespace {
-void SuccessRun(const DownloadFile::InitializeCallback& callback) {
+void SuccessRun(const DownloadFile::InitializeCallback& callback,
+ const DownloadItem::ReceivedSlices& received_slices) {
callback.Run(DOWNLOAD_INTERRUPT_REASON_NONE);
}
@@ -20,8 +21,7 @@ void SuccessRun(const DownloadFile::InitializeCallback& callback) {
MockDownloadFile::MockDownloadFile() {
// This is here because |Initialize()| is normally called right after
// construction.
- ON_CALL(*this, Initialize(_))
- .WillByDefault(::testing::Invoke(SuccessRun));
+ ON_CALL(*this, Initialize(_, _)).WillByDefault(::testing::Invoke(SuccessRun));
}
MockDownloadFile::~MockDownloadFile() {
« no previous file with comments | « content/browser/download/mock_download_file.h ('k') | content/public/test/test_file_error_injector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698