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

Side by Side Diff: chrome/browser/media_galleries/fileapi/iapps_finder_impl_win_browsertest.cc

Issue 1513043002: clang/win: Let remaining chromium_code targets build with -Wextra. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 5 years 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "base/base64.h" 5 #include "base/base64.h"
6 #include "base/base_paths_win.h" 6 #include "base/base_paths_win.h"
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/files/file_util.h" 8 #include "base/files/file_util.h"
9 #include "base/files/scoped_temp_dir.h" 9 #include "base/files/scoped_temp_dir.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 } 54 }
55 55
56 const base::FilePath& music_dir() { 56 const base::FilePath& music_dir() {
57 return music_dir_.path(); 57 return music_dir_.path();
58 } 58 }
59 59
60 void WritePrefFile(const std::string& data) { 60 void WritePrefFile(const std::string& data) {
61 base::FilePath pref_dir = 61 base::FilePath pref_dir =
62 app_data_dir().AppendASCII("Apple Computer").AppendASCII("iTunes"); 62 app_data_dir().AppendASCII("Apple Computer").AppendASCII("iTunes");
63 ASSERT_TRUE(base::CreateDirectory(pref_dir)); 63 ASSERT_TRUE(base::CreateDirectory(pref_dir));
64 ASSERT_EQ(data.size(), 64 ASSERT_EQ(static_cast<int>(data.size()),
65 base::WriteFile(pref_dir.AppendASCII("iTunesPrefs.xml"), 65 base::WriteFile(pref_dir.AppendASCII("iTunesPrefs.xml"),
66 data.data(), data.size())); 66 data.data(), data.size()));
67 } 67 }
68 68
69 void TouchDefault() { 69 void TouchDefault() {
70 base::FilePath default_dir = music_dir().AppendASCII("iTunes"); 70 base::FilePath default_dir = music_dir().AppendASCII("iTunes");
71 ASSERT_TRUE(base::CreateDirectory(default_dir)); 71 ASSERT_TRUE(base::CreateDirectory(default_dir));
72 TouchFile(default_dir.AppendASCII("iTunes Music Library.xml")); 72 TouchFile(default_dir.AppendASCII("iTunes Music Library.xml"));
73 } 73 }
74 74
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 "</plist>", EncodePath(library_xml).c_str()); 185 "</plist>", EncodePath(library_xml).c_str());
186 WritePrefFile(xml); 186 WritePrefFile(xml);
187 TestFindITunesLibrary(); 187 TestFindITunesLibrary();
188 EXPECT_TRUE(test_finder_callback_called()); 188 EXPECT_TRUE(test_finder_callback_called());
189 EXPECT_TRUE(EmptyResult()); 189 EXPECT_TRUE(EmptyResult());
190 } 190 }
191 191
192 } // namespace 192 } // namespace
193 193
194 } // namespace iapps 194 } // namespace iapps
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698