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

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

Issue 2829163004: Remove uses of base::hash_map from //chrome (Closed)
Patch Set: Downloads back Created 3 years, 5 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 1240 matching lines...) Expand 10 before | Expand all | Expand 10 after
1251 base::DictionaryValue* item1_value = NULL; 1251 base::DictionaryValue* item1_value = NULL;
1252 ASSERT_TRUE(result_list->GetDictionary(0, &item0_value)); 1252 ASSERT_TRUE(result_list->GetDictionary(0, &item0_value));
1253 ASSERT_TRUE(result_list->GetDictionary(1, &item1_value)); 1253 ASSERT_TRUE(result_list->GetDictionary(1, &item1_value));
1254 std::string item0_name, item1_name; 1254 std::string item0_name, item1_name;
1255 ASSERT_TRUE(item0_value->GetString("filename", &item0_name)); 1255 ASSERT_TRUE(item0_value->GetString("filename", &item0_name));
1256 ASSERT_TRUE(item1_value->GetString("filename", &item1_name)); 1256 ASSERT_TRUE(item1_value->GetString("filename", &item1_name));
1257 ASSERT_GT(items[0]->GetTargetFilePath().value(), 1257 ASSERT_GT(items[0]->GetTargetFilePath().value(),
1258 items[1]->GetTargetFilePath().value()); 1258 items[1]->GetTargetFilePath().value());
1259 // The order of results when orderBy is empty is unspecified. When there are 1259 // The order of results when orderBy is empty is unspecified. When there are
1260 // no sorters, DownloadQuery does not call sort(), so the order of the results 1260 // no sorters, DownloadQuery does not call sort(), so the order of the results
1261 // depends on the order of the items in base::hash_map<uint32_t,...> 1261 // depends on the order of the items in DownloadManagerImpl::downloads_,
1262 // DownloadManagerImpl::downloads_, which is unspecified and differs between 1262 // which is unspecified and differs between libc++ and libstdc++.
1263 // libc++ and libstdc++. http://crbug.com/365334 1263 // http://crbug.com/365334
1264 } 1264 }
1265 1265
1266 // Test the |danger| option for search(). 1266 // Test the |danger| option for search().
1267 IN_PROC_BROWSER_TEST_F(DownloadExtensionTest, 1267 IN_PROC_BROWSER_TEST_F(DownloadExtensionTest,
1268 DownloadExtensionTest_SearchDanger) { 1268 DownloadExtensionTest_SearchDanger) {
1269 const HistoryDownloadInfo kHistoryInfo[] = { 1269 const HistoryDownloadInfo kHistoryInfo[] = {
1270 { FILE_PATH_LITERAL("zzz"), 1270 { FILE_PATH_LITERAL("zzz"),
1271 DownloadItem::COMPLETE, 1271 DownloadItem::COMPLETE,
1272 content::DOWNLOAD_DANGER_TYPE_DANGEROUS_CONTENT }, 1272 content::DOWNLOAD_DANGER_TYPE_DANGEROUS_CONTENT },
1273 { FILE_PATH_LITERAL("baz"), 1273 { FILE_PATH_LITERAL("baz"),
(...skipping 3030 matching lines...) Expand 10 before | Expand all | Expand 10 after
4304 EXPECT_EQ(downloads::FILENAME_CONFLICT_ACTION_PROMPT, conflict_action); 4304 EXPECT_EQ(downloads::FILENAME_CONFLICT_ACTION_PROMPT, conflict_action);
4305 EXPECT_FALSE(warnings.empty()); 4305 EXPECT_FALSE(warnings.empty());
4306 EXPECT_EQ(Warning::kDownloadFilenameConflict, 4306 EXPECT_EQ(Warning::kDownloadFilenameConflict,
4307 warnings.begin()->warning_type()); 4307 warnings.begin()->warning_type());
4308 EXPECT_EQ("incumbent", warnings.begin()->extension_id()); 4308 EXPECT_EQ("incumbent", warnings.begin()->extension_id());
4309 } 4309 }
4310 4310
4311 } // namespace extensions 4311 } // namespace extensions
4312 4312
4313 #endif // http://crbug.com/306144 4313 #endif // http://crbug.com/306144
OLDNEW
« no previous file with comments | « chrome/browser/extensions/api/downloads/downloads_api.cc ('k') | chrome/browser/font_family_cache.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698