blob: 9d023722f7d4afebd9e9af653173ab6f4e149bff (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "content/browser/download/mock_download_file.h"
using ::testing::_;
using ::testing::Return;
namespace {
void SuccessRun(content::DownloadFile::InitializeCallback callback) {
callback.Run(content::DOWNLOAD_INTERRUPT_REASON_NONE);
}
} // namespace
MockDownloadFile::MockDownloadFile() {
// This is here because |Initialize()| is normally called right after
// construction.
ON_CALL(*this, Initialize(_))
.WillByDefault(::testing::Invoke(SuccessRun));
}
MockDownloadFile::~MockDownloadFile() {
}
|