OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/ntp_snippets/fake_download_item.h" | 5 #include "chrome/browser/ntp_snippets/fake_download_item.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 | 8 |
9 using content::DownloadItem; | 9 using content::DownloadItem; |
10 | 10 |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 } | 48 } |
49 | 49 |
50 void FakeDownloadItem::SetId(uint32_t id) { | 50 void FakeDownloadItem::SetId(uint32_t id) { |
51 id_ = id; | 51 id_ = id; |
52 } | 52 } |
53 | 53 |
54 uint32_t FakeDownloadItem::GetId() const { | 54 uint32_t FakeDownloadItem::GetId() const { |
55 return id_; | 55 return id_; |
56 } | 56 } |
57 | 57 |
| 58 void FakeDownloadItem::SetGuid(const std::string& guid) { |
| 59 guid_ = guid; |
| 60 } |
| 61 |
| 62 const std::string& FakeDownloadItem::GetGuid() const { |
| 63 return guid_; |
| 64 } |
| 65 |
58 void FakeDownloadItem::SetURL(const GURL& url) { | 66 void FakeDownloadItem::SetURL(const GURL& url) { |
59 url_ = url; | 67 url_ = url; |
60 } | 68 } |
61 | 69 |
62 const GURL& FakeDownloadItem::GetURL() const { | 70 const GURL& FakeDownloadItem::GetURL() const { |
63 return url_; | 71 return url_; |
64 } | 72 } |
65 | 73 |
66 void FakeDownloadItem::SetTargetFilePath(const base::FilePath& file_path) { | 74 void FakeDownloadItem::SetTargetFilePath(const base::FilePath& file_path) { |
67 file_path_ = file_path; | 75 file_path_ = file_path; |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
149 } | 157 } |
150 | 158 |
151 void FakeDownloadItem::OpenDownload() { | 159 void FakeDownloadItem::OpenDownload() { |
152 NOTREACHED(); | 160 NOTREACHED(); |
153 } | 161 } |
154 | 162 |
155 void FakeDownloadItem::ShowDownloadInShell() { | 163 void FakeDownloadItem::ShowDownloadInShell() { |
156 NOTREACHED(); | 164 NOTREACHED(); |
157 } | 165 } |
158 | 166 |
159 const std::string& FakeDownloadItem::GetGuid() const { | |
160 NOTREACHED(); | |
161 return dummy_string; | |
162 } | |
163 | |
164 content::DownloadInterruptReason FakeDownloadItem::GetLastReason() const { | 167 content::DownloadInterruptReason FakeDownloadItem::GetLastReason() const { |
165 NOTREACHED(); | 168 NOTREACHED(); |
166 return content::DownloadInterruptReason(); | 169 return content::DownloadInterruptReason(); |
167 } | 170 } |
168 | 171 |
169 bool FakeDownloadItem::IsPaused() const { | 172 bool FakeDownloadItem::IsPaused() const { |
170 NOTREACHED(); | 173 NOTREACHED(); |
171 return false; | 174 return false; |
172 } | 175 } |
173 | 176 |
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
398 void FakeDownloadItem::SetDisplayName(const base::FilePath& name) { | 401 void FakeDownloadItem::SetDisplayName(const base::FilePath& name) { |
399 NOTREACHED(); | 402 NOTREACHED(); |
400 } | 403 } |
401 | 404 |
402 std::string FakeDownloadItem::DebugString(bool verbose) const { | 405 std::string FakeDownloadItem::DebugString(bool verbose) const { |
403 NOTREACHED(); | 406 NOTREACHED(); |
404 return std::string(); | 407 return std::string(); |
405 } | 408 } |
406 | 409 |
407 } // namespace test | 410 } // namespace test |
OLD | NEW |