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 "base/stl_util.h" | 5 #include "base/stl_util.h" |
6 #include "testing/gtest/include/gtest/gtest.h" | 6 #include "testing/gtest/include/gtest/gtest.h" |
7 #include "webkit/browser/fileapi/file_system_context.h" | 7 #include "webkit/browser/fileapi/file_system_context.h" |
8 #include "webkit/browser/fileapi/file_system_file_util.h" | 8 #include "webkit/browser/fileapi/file_system_file_util.h" |
9 #include "webkit/browser/fileapi/file_system_operation_context.h" | 9 #include "webkit/browser/fileapi/file_system_operation_context.h" |
10 #include "webkit/browser/fileapi/file_system_task_runners.h" | 10 #include "webkit/browser/fileapi/file_system_task_runners.h" |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
81 | 81 |
82 FileSystemURL URL(const std::string& path) { | 82 FileSystemURL URL(const std::string& path) { |
83 return file_system_.URL(path); | 83 return file_system_.URL(path); |
84 } | 84 } |
85 | 85 |
86 FileSystemContext* file_system_context() { | 86 FileSystemContext* file_system_context() { |
87 return file_system_.file_system_context(); | 87 return file_system_.file_system_context(); |
88 } | 88 } |
89 | 89 |
90 LocalFileChangeTracker* change_tracker() { | 90 LocalFileChangeTracker* change_tracker() { |
91 return file_system_context()->change_tracker(); | 91 return file_system_.mount_provider()->change_tracker(); |
92 } | 92 } |
93 | 93 |
94 ScopedEnableSyncFSDirectoryOperation enable_directory_operation_; | 94 ScopedEnableSyncFSDirectoryOperation enable_directory_operation_; |
95 | 95 |
96 base::ScopedTempDir data_dir_; | 96 base::ScopedTempDir data_dir_; |
97 base::MessageLoop message_loop_; | 97 base::MessageLoop message_loop_; |
98 | 98 |
99 CannedSyncableFileSystem file_system_; | 99 CannedSyncableFileSystem file_system_; |
100 scoped_refptr<LocalFileSyncContext> sync_context_; | 100 scoped_refptr<LocalFileSyncContext> sync_context_; |
101 | 101 |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
281 // Now try copying the directory into the syncable file system, which should | 281 // Now try copying the directory into the syncable file system, which should |
282 // fail if directory operation is disabled. (http://crbug.com/161442) | 282 // fail if directory operation is disabled. (http://crbug.com/161442) |
283 EXPECT_NE(base::PLATFORM_FILE_OK, | 283 EXPECT_NE(base::PLATFORM_FILE_OK, |
284 file_system_.Copy(kSrcDir, URL("dest"))); | 284 file_system_.Copy(kSrcDir, URL("dest"))); |
285 | 285 |
286 other_file_system_.TearDown(); | 286 other_file_system_.TearDown(); |
287 SetEnableSyncFSDirectoryOperation(was_enabled); | 287 SetEnableSyncFSDirectoryOperation(was_enabled); |
288 } | 288 } |
289 | 289 |
290 } // namespace sync_file_system | 290 } // namespace sync_file_system |
OLD | NEW |