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

Side by Side Diff: chrome/browser/media_galleries/win/mtp_device_delegate_impl_win_unittest.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 <vector> 5 #include <vector>
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/run_loop.h" 10 #include "base/run_loop.h"
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 AttachDevice(StorageInfo::MTP_OR_PTP, "mtp_fake_id", location); 160 AttachDevice(StorageInfo::MTP_OR_PTP, "mtp_fake_id", location);
161 161
162 FSInfoMap results; 162 FSInfoMap results;
163 MediaFileSystemRegistry* registry = 163 MediaFileSystemRegistry* registry =
164 g_browser_process->media_file_system_registry(); 164 g_browser_process->media_file_system_registry();
165 registry->GetMediaFileSystemsForExtension( 165 registry->GetMediaFileSystemsForExtension(
166 web_contents(), extension_.get(), 166 web_contents(), extension_.get(),
167 base::Bind(&GetGalleryInfoCallback, base::Unretained(&results))); 167 base::Bind(&GetGalleryInfoCallback, base::Unretained(&results)));
168 base::RunLoop().RunUntilIdle(); 168 base::RunLoop().RunUntilIdle();
169 169
170 ASSERT_EQ(media_directories_.num_galleries() + 1, results.size()); 170 ASSERT_EQ(media_directories_.num_galleries() + 1u, results.size());
171 bool checked = false; 171 bool checked = false;
172 for (FSInfoMap::iterator i = results.begin(); i != results.end(); ++i) { 172 for (FSInfoMap::iterator i = results.begin(); i != results.end(); ++i) {
173 MediaFileSystemInfo info = i->second; 173 MediaFileSystemInfo info = i->second;
174 if (info.path == location) { 174 if (info.path == location) {
175 CheckGalleryInfo(info, location.LossyDisplayName(), location, true, true); 175 CheckGalleryInfo(info, location.LossyDisplayName(), location, true, true);
176 checked = true; 176 checked = true;
177 break; 177 break;
178 } 178 }
179 } 179 }
180 EXPECT_TRUE(checked); 180 EXPECT_TRUE(checked);
181 } 181 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698