OLD | NEW |
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 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 | 92 |
93 base::RunLoop runloop; | 93 base::RunLoop runloop; |
94 browser_process->media_file_system_registry()->GetPreferences(profile())-> | 94 browser_process->media_file_system_registry()->GetPreferences(profile())-> |
95 EnsureInitialized(runloop.QuitClosure()); | 95 EnsureInitialized(runloop.QuitClosure()); |
96 runloop.Run(); | 96 runloop.Run(); |
97 | 97 |
98 extensions::TestExtensionSystem* extension_system( | 98 extensions::TestExtensionSystem* extension_system( |
99 static_cast<extensions::TestExtensionSystem*>( | 99 static_cast<extensions::TestExtensionSystem*>( |
100 extensions::ExtensionSystem::Get(profile()))); | 100 extensions::ExtensionSystem::Get(profile()))); |
101 extension_system->CreateExtensionService( | 101 extension_system->CreateExtensionService( |
102 CommandLine::ForCurrentProcess(), base::FilePath(), false); | 102 base::CommandLine::ForCurrentProcess(), base::FilePath(), false); |
103 | 103 |
104 std::vector<std::string> all_permissions; | 104 std::vector<std::string> all_permissions; |
105 all_permissions.push_back("allAutoDetected"); | 105 all_permissions.push_back("allAutoDetected"); |
106 all_permissions.push_back("read"); | 106 all_permissions.push_back("read"); |
107 extension_ = AddMediaGalleriesApp("all", all_permissions, profile()); | 107 extension_ = AddMediaGalleriesApp("all", all_permissions, profile()); |
108 } | 108 } |
109 | 109 |
110 void MTPDeviceDelegateImplWinTest::TearDown() { | 110 void MTPDeviceDelegateImplWinTest::TearDown() { |
111 // Windows storage monitor must be destroyed on the same thread | 111 // Windows storage monitor must be destroyed on the same thread |
112 // as construction. | 112 // as construction. |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
173 for (FSInfoMap::iterator i = results.begin(); i != results.end(); ++i) { | 173 for (FSInfoMap::iterator i = results.begin(); i != results.end(); ++i) { |
174 MediaFileSystemInfo info = i->second; | 174 MediaFileSystemInfo info = i->second; |
175 if (info.path == location) { | 175 if (info.path == location) { |
176 CheckGalleryInfo(info, location.LossyDisplayName(), location, true, true); | 176 CheckGalleryInfo(info, location.LossyDisplayName(), location, true, true); |
177 checked = true; | 177 checked = true; |
178 break; | 178 break; |
179 } | 179 } |
180 } | 180 } |
181 EXPECT_TRUE(checked); | 181 EXPECT_TRUE(checked); |
182 } | 182 } |
OLD | NEW |