| OLD | NEW |
| 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 #include "chrome/browser/chromeos/drive/drive_file_system.h" | 5 #include "chrome/browser/chromeos/drive/drive_file_system.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 265 } | 265 } |
| 266 | 266 |
| 267 bool LoadChangeFeed(const std::string& filename) { | 267 bool LoadChangeFeed(const std::string& filename) { |
| 268 return LoadFeed(filename, true); | 268 return LoadFeed(filename, true); |
| 269 } | 269 } |
| 270 | 270 |
| 271 bool LoadFeed(const std::string& filename, bool is_delta_feed) { | 271 bool LoadFeed(const std::string& filename, bool is_delta_feed) { |
| 272 if (!test_util::LoadChangeFeed(filename, | 272 if (!test_util::LoadChangeFeed(filename, |
| 273 file_system_->change_list_loader(), | 273 file_system_->change_list_loader(), |
| 274 is_delta_feed, | 274 is_delta_feed, |
| 275 fake_drive_service_->GetRootResourceId(), |
| 275 root_feed_changestamp_)) { | 276 root_feed_changestamp_)) { |
| 276 return false; | 277 return false; |
| 277 } | 278 } |
| 278 root_feed_changestamp_++; | 279 root_feed_changestamp_++; |
| 279 return true; | 280 return true; |
| 280 } | 281 } |
| 281 | 282 |
| 282 void AddDirectoryFromFile(const base::FilePath& directory_path, | 283 void AddDirectoryFromFile(const base::FilePath& directory_path, |
| 283 const std::string& filename) { | 284 const std::string& filename) { |
| 284 scoped_ptr<Value> atom = google_apis::test_util::LoadJSONFile(filename); | 285 scoped_ptr<Value> atom = google_apis::test_util::LoadJSONFile(filename); |
| (...skipping 1893 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2178 | 2179 |
| 2179 // An app for foo.exe should now be found, as the registry was loaded. | 2180 // An app for foo.exe should now be found, as the registry was loaded. |
| 2180 drive_webapps_registry_->GetWebAppsForFile( | 2181 drive_webapps_registry_->GetWebAppsForFile( |
| 2181 base::FilePath(FILE_PATH_LITERAL("foo.exe")), | 2182 base::FilePath(FILE_PATH_LITERAL("foo.exe")), |
| 2182 "" /* mime_type */, | 2183 "" /* mime_type */, |
| 2183 &apps); | 2184 &apps); |
| 2184 EXPECT_EQ(1U, apps.size()); | 2185 EXPECT_EQ(1U, apps.size()); |
| 2185 } | 2186 } |
| 2186 | 2187 |
| 2187 } // namespace drive | 2188 } // namespace drive |
| OLD | NEW |