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

Side by Side Diff: chrome/browser/extensions/api/downloads/downloads_api_browsertest.cc

Issue 1875033005: [Downloads/History] Add tab-url and tab-referrer-url to DownloadRow (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@guid-fix
Patch Set: Update expectations for DownloadUIController test. Created 4 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 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 // Disable everything on windows only. http://crbug.com/306144 5 // Disable everything on windows only. http://crbug.com/306144
6 #ifndef OS_WIN 6 #ifndef OS_WIN
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 414 matching lines...) Expand 10 before | Expand all | Expand 10 after
425 CHECK_EQ(0, static_cast<int>(items->size())); 425 CHECK_EQ(0, static_cast<int>(items->size()));
426 std::vector<GURL> url_chain; 426 std::vector<GURL> url_chain;
427 url_chain.push_back(GURL()); 427 url_chain.push_back(GURL());
428 for (size_t i = 0; i < count; ++i) { 428 for (size_t i = 0; i < count; ++i) {
429 DownloadItem* item = GetOnRecordManager()->CreateDownloadItem( 429 DownloadItem* item = GetOnRecordManager()->CreateDownloadItem(
430 base::GenerateGUID(), 430 base::GenerateGUID(),
431 content::DownloadItem::kInvalidId + 1 + i, 431 content::DownloadItem::kInvalidId + 1 + i,
432 downloads_directory().Append(history_info[i].filename), 432 downloads_directory().Append(history_info[i].filename),
433 downloads_directory().Append(history_info[i].filename), 433 downloads_directory().Append(history_info[i].filename),
434 url_chain, 434 url_chain,
435 GURL(), // URL Chain, referrer 435 GURL(),
436 GURL(),
437 GURL(),
436 std::string(), 438 std::string(),
437 std::string(), // mime_type, original_mime_type 439 std::string(), // mime_type, original_mime_type
438 current, 440 current,
439 current, // start_time, end_time 441 current, // start_time, end_time
440 std::string(), 442 std::string(),
441 std::string(), // etag, last_modified 443 std::string(), // etag, last_modified
442 1, 444 1,
443 1, // received_bytes, total_bytes 445 1, // received_bytes, total_bytes
444 std::string(), // hash 446 std::string(), // hash
445 history_info[i].state, // state 447 history_info[i].state, // state
(...skipping 3742 matching lines...) Expand 10 before | Expand all | Expand 10 after
4188 EXPECT_EQ(downloads::FILENAME_CONFLICT_ACTION_PROMPT, conflict_action); 4190 EXPECT_EQ(downloads::FILENAME_CONFLICT_ACTION_PROMPT, conflict_action);
4189 EXPECT_FALSE(warnings.empty()); 4191 EXPECT_FALSE(warnings.empty());
4190 EXPECT_EQ(Warning::kDownloadFilenameConflict, 4192 EXPECT_EQ(Warning::kDownloadFilenameConflict,
4191 warnings.begin()->warning_type()); 4193 warnings.begin()->warning_type());
4192 EXPECT_EQ("incumbent", warnings.begin()->extension_id()); 4194 EXPECT_EQ("incumbent", warnings.begin()->extension_id());
4193 } 4195 }
4194 4196
4195 } // namespace extensions 4197 } // namespace extensions
4196 4198
4197 #endif // http://crbug.com/306144 4199 #endif // http://crbug.com/306144
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698