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

Side by Side Diff: content/browser/download/download_item_impl_unittest.cc

Issue 2044233002: Remove download resumption feature flag. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "content/browser/download/download_item_impl.h" 5 #include "content/browser/download/download_item_impl.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <iterator> 9 #include <iterator>
10 #include <queue> 10 #include <queue>
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after
237 0xd2, 0xfc, 0x16, 0xa1, 0xf5, 0x1a, 0x65, 0x3a, 0xa0, 0x19, 0x64, 237 0xd2, 0xfc, 0x16, 0xa1, 0xf5, 0x1a, 0x65, 0x3a, 0xa0, 0x19, 0x64,
238 0xef, 0x9c, 0x92, 0x33, 0x36, 0xe1, 0x06, 0x53, 0xfe, 0xc1, 0x95, 238 0xef, 0x9c, 0x92, 0x33, 0x36, 0xe1, 0x06, 0x53, 0xfe, 0xc1, 0x95,
239 0xf4, 0x93, 0x45, 0x8b, 0x3b, 0x21, 0x89, 0x0e, 0x1b, 0x97}; 239 0xf4, 0x93, 0x45, 0x8b, 0x3b, 0x21, 0x89, 0x0e, 0x1b, 0x97};
240 240
241 } // namespace 241 } // namespace
242 242
243 class DownloadItemTest : public testing::Test { 243 class DownloadItemTest : public testing::Test {
244 public: 244 public:
245 DownloadItemTest() 245 DownloadItemTest()
246 : delegate_(), next_download_id_(DownloadItem::kInvalidId + 1) { 246 : delegate_(), next_download_id_(DownloadItem::kInvalidId + 1) {
247 base::FeatureList::ClearInstanceForTesting();
248 std::unique_ptr<base::FeatureList> feature_list(new base::FeatureList);
249 feature_list->InitializeFromCommandLine(features::kDownloadResumption.name,
250 std::string());
251 base::FeatureList::SetInstance(std::move(feature_list));
252
253 create_info_.reset(new DownloadCreateInfo()); 247 create_info_.reset(new DownloadCreateInfo());
254 create_info_->save_info = 248 create_info_->save_info =
255 std::unique_ptr<DownloadSaveInfo>(new DownloadSaveInfo()); 249 std::unique_ptr<DownloadSaveInfo>(new DownloadSaveInfo());
256 create_info_->save_info->prompt_for_save_location = false; 250 create_info_->save_info->prompt_for_save_location = false;
257 create_info_->url_chain.push_back(GURL("http://example.com/download")); 251 create_info_->url_chain.push_back(GURL("http://example.com/download"));
258 create_info_->etag = "SomethingToSatisfyResumption"; 252 create_info_->etag = "SomethingToSatisfyResumption";
259 } 253 }
260 254
261 ~DownloadItemTest() { 255 ~DownloadItemTest() {
262 RunAllPendingInMessageLoops(); 256 RunAllPendingInMessageLoops();
(...skipping 1766 matching lines...) Expand 10 before | Expand all | Expand 10 after
2029 2023
2030 item_->Cancel(true); 2024 item_->Cancel(true);
2031 RunAllPendingInMessageLoops(); 2025 RunAllPendingInMessageLoops();
2032 } 2026 }
2033 2027
2034 TEST(MockDownloadItem, Compiles) { 2028 TEST(MockDownloadItem, Compiles) {
2035 MockDownloadItem mock_item; 2029 MockDownloadItem mock_item;
2036 } 2030 }
2037 2031
2038 } // namespace content 2032 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/download/download_item_impl.cc ('k') | content/public/common/content_features.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698