| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/file_system_provider/operations/open_file.h" | 5 #include "chrome/browser/chromeos/file_system_provider/operations/open_file.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/files/file.h" | 10 #include "base/files/file.h" |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 64 DISALLOW_COPY_AND_ASSIGN(CallbackLogger); | 64 DISALLOW_COPY_AND_ASSIGN(CallbackLogger); |
| 65 }; | 65 }; |
| 66 | 66 |
| 67 } // namespace | 67 } // namespace |
| 68 | 68 |
| 69 class FileSystemProviderOperationsOpenFileTest : public testing::Test { | 69 class FileSystemProviderOperationsOpenFileTest : public testing::Test { |
| 70 protected: | 70 protected: |
| 71 FileSystemProviderOperationsOpenFileTest() {} | 71 FileSystemProviderOperationsOpenFileTest() {} |
| 72 virtual ~FileSystemProviderOperationsOpenFileTest() {} | 72 virtual ~FileSystemProviderOperationsOpenFileTest() {} |
| 73 | 73 |
| 74 virtual void SetUp() OVERRIDE { | 74 virtual void SetUp() override { |
| 75 file_system_info_ = | 75 file_system_info_ = |
| 76 ProvidedFileSystemInfo(kExtensionId, | 76 ProvidedFileSystemInfo(kExtensionId, |
| 77 kFileSystemId, | 77 kFileSystemId, |
| 78 "" /* display_name */, | 78 "" /* display_name */, |
| 79 false /* writable */, | 79 false /* writable */, |
| 80 base::FilePath() /* mount_path */); | 80 base::FilePath() /* mount_path */); |
| 81 } | 81 } |
| 82 | 82 |
| 83 ProvidedFileSystemInfo file_system_info_; | 83 ProvidedFileSystemInfo file_system_info_; |
| 84 }; | 84 }; |
| (...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 226 base::File::FILE_ERROR_TOO_MANY_OPENED); | 226 base::File::FILE_ERROR_TOO_MANY_OPENED); |
| 227 ASSERT_EQ(1u, callback_logger.events().size()); | 227 ASSERT_EQ(1u, callback_logger.events().size()); |
| 228 CallbackLogger::Event* event = callback_logger.events()[0]; | 228 CallbackLogger::Event* event = callback_logger.events()[0]; |
| 229 EXPECT_EQ(base::File::FILE_ERROR_TOO_MANY_OPENED, event->result()); | 229 EXPECT_EQ(base::File::FILE_ERROR_TOO_MANY_OPENED, event->result()); |
| 230 ASSERT_EQ(0, event->file_handle()); | 230 ASSERT_EQ(0, event->file_handle()); |
| 231 } | 231 } |
| 232 | 232 |
| 233 } // namespace operations | 233 } // namespace operations |
| 234 } // namespace file_system_provider | 234 } // namespace file_system_provider |
| 235 } // namespace chromeos | 235 } // namespace chromeos |
| OLD | NEW |