Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(543)

Side by Side Diff: content/browser/fileapi/file_system_operation_impl_unittest.cc

Issue 2815743002: Move a couple of blob tests next to the files they cover. (Closed)
Patch Set: Fix gn check, take 2. Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 "storage/browser/fileapi/file_system_operation_impl.h" 5 #include "storage/browser/fileapi/file_system_operation_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
11 11
12 #include "base/bind.h" 12 #include "base/bind.h"
13 #include "base/files/file_util.h" 13 #include "base/files/file_util.h"
14 #include "base/files/scoped_temp_dir.h" 14 #include "base/files/scoped_temp_dir.h"
15 #include "base/logging.h" 15 #include "base/logging.h"
16 #include "base/macros.h" 16 #include "base/macros.h"
17 #include "base/memory/ptr_util.h" 17 #include "base/memory/ptr_util.h"
18 #include "base/memory/weak_ptr.h" 18 #include "base/memory/weak_ptr.h"
19 #include "base/run_loop.h" 19 #include "base/run_loop.h"
20 #include "base/strings/stringprintf.h" 20 #include "base/strings/stringprintf.h"
21 #include "base/threading/thread_task_runner_handle.h" 21 #include "base/threading/thread_task_runner_handle.h"
22 #include "content/browser/fileapi/mock_file_change_observer.h" 22 #include "content/browser/fileapi/mock_file_change_observer.h"
23 #include "content/browser/fileapi/mock_file_update_observer.h" 23 #include "content/browser/fileapi/mock_file_update_observer.h"
24 #include "content/browser/quota/mock_quota_manager.h" 24 #include "content/browser/quota/mock_quota_manager.h"
25 #include "content/browser/quota/mock_quota_manager_proxy.h" 25 #include "content/browser/quota/mock_quota_manager_proxy.h"
26 #include "content/public/test/async_file_test_helper.h"
27 #include "content/public/test/sandbox_file_system_test_helper.h" 26 #include "content/public/test/sandbox_file_system_test_helper.h"
28 #include "storage/browser/blob/shareable_file_reference.h" 27 #include "storage/browser/blob/shareable_file_reference.h"
29 #include "storage/browser/fileapi/file_system_context.h" 28 #include "storage/browser/fileapi/file_system_context.h"
30 #include "storage/browser/fileapi/file_system_file_util.h" 29 #include "storage/browser/fileapi/file_system_file_util.h"
31 #include "storage/browser/fileapi/file_system_operation_context.h" 30 #include "storage/browser/fileapi/file_system_operation_context.h"
32 #include "storage/browser/fileapi/file_system_operation_runner.h" 31 #include "storage/browser/fileapi/file_system_operation_runner.h"
33 #include "storage/browser/fileapi/sandbox_file_system_backend.h" 32 #include "storage/browser/fileapi/sandbox_file_system_backend.h"
34 #include "storage/browser/quota/quota_manager.h" 33 #include "storage/browser/quota/quota_manager.h"
35 #include "storage/browser/quota/quota_manager_proxy.h" 34 #include "storage/browser/quota/quota_manager_proxy.h"
35 #include "storage/browser/test/async_file_test_helper.h"
36 #include "storage/common/fileapi/file_system_util.h" 36 #include "storage/common/fileapi/file_system_util.h"
37 #include "testing/gtest/include/gtest/gtest.h" 37 #include "testing/gtest/include/gtest/gtest.h"
38 #include "url/gurl.h" 38 #include "url/gurl.h"
39 39
40 using content::AsyncFileTestHelper; 40 using content::AsyncFileTestHelper;
41 using storage::FileSystemOperation; 41 using storage::FileSystemOperation;
42 using storage::FileSystemOperationContext; 42 using storage::FileSystemOperationContext;
43 using storage::FileSystemOperationRunner; 43 using storage::FileSystemOperationRunner;
44 using storage::FileSystemURL; 44 using storage::FileSystemURL;
45 using storage::QuotaManager; 45 using storage::QuotaManager;
(...skipping 1257 matching lines...) Expand 10 before | Expand all | Expand 10 after
1303 FileSystemURL src_file(CreateFile("src")); 1303 FileSystemURL src_file(CreateFile("src"));
1304 FileSystemURL dest_file(CreateFile("dest")); 1304 FileSystemURL dest_file(CreateFile("dest"));
1305 1305
1306 EXPECT_EQ(base::File::FILE_OK, Truncate(dest_file, 6)); 1306 EXPECT_EQ(base::File::FILE_OK, Truncate(dest_file, 6));
1307 EXPECT_EQ(base::File::FILE_OK, 1307 EXPECT_EQ(base::File::FILE_OK,
1308 Copy(src_file, dest_file, FileSystemOperation::OPTION_NONE)); 1308 Copy(src_file, dest_file, FileSystemOperation::OPTION_NONE));
1309 EXPECT_EQ(0, GetFileSize("dest")); 1309 EXPECT_EQ(0, GetFileSize("dest"));
1310 } 1310 }
1311 1311
1312 } // namespace content 1312 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698