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

Side by Side Diff: chrome/browser/download/download_util_unittest.cc

Issue 6973052: When the download folder does not exist, change the download folder to a user's "Downloads" (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Overrides the user's "Downloads" folder in DownloadPrefs Created 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/download/download_util.h" 5 #include "chrome/browser/download/download_util.h"
6 6
7 #if defined(OS_POSIX) && !defined(OS_MACOSX) 7 #if defined(OS_POSIX) && !defined(OS_MACOSX)
8 #include <locale.h> 8 #include <locale.h>
9 #endif 9 #endif
10 10
(...skipping 561 matching lines...) Expand 10 before | Expand all | Expand 10 after
572 572
573 TEST(DownloadUtilTest, GenerateSafeFileName) { 573 TEST(DownloadUtilTest, GenerateSafeFileName) {
574 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(kSafeFilenameCases); ++i) { 574 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(kSafeFilenameCases); ++i) {
575 FilePath path(kSafeFilenameCases[i].path); 575 FilePath path(kSafeFilenameCases[i].path);
576 download_util::GenerateSafeFileName(kSafeFilenameCases[i].mime_type, &path); 576 download_util::GenerateSafeFileName(kSafeFilenameCases[i].mime_type, &path);
577 EXPECT_EQ(kSafeFilenameCases[i].expected_path, path.value()) << i; 577 EXPECT_EQ(kSafeFilenameCases[i].expected_path, path.value()) << i;
578 } 578 }
579 } 579 }
580 580
581 } // namespace 581 } // namespace
582
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698