| 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 "chrome/browser/sync_file_system/local/local_file_sync_context.h" | 5 #include "chrome/browser/sync_file_system/local/local_file_sync_context.h" |
| 6 | 6 |
| 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" |
| 11 #include "base/files/file_path.h" | 11 #include "base/files/file_path.h" |
| 12 #include "base/files/file_util.h" | 12 #include "base/files/file_util.h" |
| 13 #include "base/message_loop/message_loop.h" | 13 #include "base/message_loop/message_loop.h" |
| 14 #include "base/stl_util.h" | 14 #include "base/stl_util.h" |
| 15 #include "chrome/browser/sync_file_system/local/canned_syncable_file_system.h" | 15 #include "chrome/browser/sync_file_system/local/canned_syncable_file_system.h" |
| 16 #include "chrome/browser/sync_file_system/local/local_file_change_tracker.h" | 16 #include "chrome/browser/sync_file_system/local/local_file_change_tracker.h" |
| 17 #include "chrome/browser/sync_file_system/local/sync_file_system_backend.h" | 17 #include "chrome/browser/sync_file_system/local/sync_file_system_backend.h" |
| 18 #include "chrome/browser/sync_file_system/sync_file_metadata.h" | 18 #include "chrome/browser/sync_file_system/sync_file_metadata.h" |
| 19 #include "chrome/browser/sync_file_system/sync_status_code.h" | 19 #include "chrome/browser/sync_file_system/sync_status_code.h" |
| 20 #include "chrome/browser/sync_file_system/syncable_file_system_util.h" | 20 #include "chrome/browser/sync_file_system/syncable_file_system_util.h" |
| 21 #include "content/public/browser/browser_thread.h" | 21 #include "content/public/browser/browser_thread.h" |
| 22 #include "content/public/test/mock_blob_url_request_context.h" | 22 #include "content/public/test/mock_blob_url_request_context.h" |
| 23 #include "content/public/test/test_browser_thread_bundle.h" | 23 #include "content/public/test/test_browser_thread_bundle.h" |
| 24 #include "storage/browser/fileapi/file_system_context.h" |
| 25 #include "storage/browser/fileapi/file_system_operation_runner.h" |
| 26 #include "storage/browser/fileapi/isolated_context.h" |
| 24 #include "storage/common/blob/scoped_file.h" | 27 #include "storage/common/blob/scoped_file.h" |
| 25 #include "testing/gtest/include/gtest/gtest.h" | 28 #include "testing/gtest/include/gtest/gtest.h" |
| 26 #include "third_party/leveldatabase/src/helpers/memenv/memenv.h" | 29 #include "third_party/leveldatabase/src/helpers/memenv/memenv.h" |
| 27 #include "third_party/leveldatabase/src/include/leveldb/env.h" | 30 #include "third_party/leveldatabase/src/include/leveldb/env.h" |
| 28 #include "webkit/browser/fileapi/file_system_context.h" | |
| 29 #include "webkit/browser/fileapi/file_system_operation_runner.h" | |
| 30 #include "webkit/browser/fileapi/isolated_context.h" | |
| 31 | 31 |
| 32 #define FPL FILE_PATH_LITERAL | 32 #define FPL FILE_PATH_LITERAL |
| 33 | 33 |
| 34 using content::BrowserThread; | 34 using content::BrowserThread; |
| 35 using storage::FileSystemContext; | 35 using storage::FileSystemContext; |
| 36 using storage::FileSystemURL; | 36 using storage::FileSystemURL; |
| 37 using storage::FileSystemURLSet; | 37 using storage::FileSystemURLSet; |
| 38 | 38 |
| 39 // This tests LocalFileSyncContext behavior in multi-thread / | 39 // This tests LocalFileSyncContext behavior in multi-thread / |
| 40 // multi-file-system-context environment. | 40 // multi-file-system-context environment. |
| (...skipping 909 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 950 | 950 |
| 951 // Make sure kDir and kFile are created by ApplyRemoteChange. | 951 // Make sure kDir and kFile are created by ApplyRemoteChange. |
| 952 EXPECT_EQ(base::File::FILE_OK, file_system.FileExists(kFile)); | 952 EXPECT_EQ(base::File::FILE_OK, file_system.FileExists(kFile)); |
| 953 EXPECT_EQ(base::File::FILE_OK, file_system.DirectoryExists(kDir)); | 953 EXPECT_EQ(base::File::FILE_OK, file_system.DirectoryExists(kDir)); |
| 954 | 954 |
| 955 sync_context_->ShutdownOnUIThread(); | 955 sync_context_->ShutdownOnUIThread(); |
| 956 file_system.TearDown(); | 956 file_system.TearDown(); |
| 957 } | 957 } |
| 958 | 958 |
| 959 } // namespace sync_file_system | 959 } // namespace sync_file_system |
| OLD | NEW |