| 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 <errno.h> | 5 #include <errno.h> |
| 6 #include <string> | 6 #include <string> |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
| (...skipping 1201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1212 EXPECT_EQ(base::PLATFORM_FILE_ERROR_NOT_A_DIRECTORY, | 1212 EXPECT_EQ(base::PLATFORM_FILE_ERROR_NOT_A_DIRECTORY, |
| 1213 callback_helper_->last_error_); | 1213 callback_helper_->last_error_); |
| 1214 | 1214 |
| 1215 EXPECT_EQ(src_file, FindFile(src_file_path)); | 1215 EXPECT_EQ(src_file, FindFile(src_file_path)); |
| 1216 EXPECT_EQ(src_file, FindFileByResource(src_file_path_resource)); | 1216 EXPECT_EQ(src_file, FindFileByResource(src_file_path_resource)); |
| 1217 EXPECT_EQ(dest_parent, FindFile(dest_parent_path)); | 1217 EXPECT_EQ(dest_parent, FindFile(dest_parent_path)); |
| 1218 | 1218 |
| 1219 EXPECT_TRUE(FindFile(dest_file_path) == NULL); | 1219 EXPECT_TRUE(FindFile(dest_file_path) == NULL); |
| 1220 } | 1220 } |
| 1221 | 1221 |
| 1222 TEST_F(GDataFileSystemTest, RemoveFiles) { | 1222 // Race in shutdown. http://crbug.com/119712 |
| 1223 TEST_F(GDataFileSystemTest, DISABLED_RemoveFiles) { |
| 1223 EXPECT_CALL(*mock_sync_client_, OnCacheInitialized()).Times(1); | 1224 EXPECT_CALL(*mock_sync_client_, OnCacheInitialized()).Times(1); |
| 1224 | 1225 |
| 1225 LoadRootFeedDocument("root_feed.json"); | 1226 LoadRootFeedDocument("root_feed.json"); |
| 1226 | 1227 |
| 1227 FilePath nonexisting_file(FILE_PATH_LITERAL("gdata/Dummy file.txt")); | 1228 FilePath nonexisting_file(FILE_PATH_LITERAL("gdata/Dummy file.txt")); |
| 1228 FilePath file_in_root(FILE_PATH_LITERAL("gdata/File 1.txt")); | 1229 FilePath file_in_root(FILE_PATH_LITERAL("gdata/File 1.txt")); |
| 1229 FilePath dir_in_root(FILE_PATH_LITERAL("gdata/Directory 1")); | 1230 FilePath dir_in_root(FILE_PATH_LITERAL("gdata/Directory 1")); |
| 1230 FilePath file_in_subdir( | 1231 FilePath file_in_subdir( |
| 1231 FILE_PATH_LITERAL("gdata/Directory 1/SubDirectory File 1.txt")); | 1232 FILE_PATH_LITERAL("gdata/Directory 1/SubDirectory File 1.txt")); |
| 1232 | 1233 |
| (...skipping 612 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1845 | 1846 |
| 1846 EXPECT_CALL(*mock_doc_service_, GetAccountMetadata(_)); | 1847 EXPECT_CALL(*mock_doc_service_, GetAccountMetadata(_)); |
| 1847 | 1848 |
| 1848 file_system_->GetAvailableSpace(callback); | 1849 file_system_->GetAvailableSpace(callback); |
| 1849 message_loop_.RunAllPending(); // Wait to get our result. | 1850 message_loop_.RunAllPending(); // Wait to get our result. |
| 1850 EXPECT_EQ(1234, callback_helper_->quota_bytes_used_); | 1851 EXPECT_EQ(1234, callback_helper_->quota_bytes_used_); |
| 1851 EXPECT_EQ(12345, callback_helper_->quota_bytes_total_); | 1852 EXPECT_EQ(12345, callback_helper_->quota_bytes_total_); |
| 1852 } | 1853 } |
| 1853 | 1854 |
| 1854 } // namespace gdata | 1855 } // namespace gdata |
| OLD | NEW |