| 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/get_metadata.h
" | 5 #include "chrome/browser/chromeos/file_system_provider/operations/get_metadata.h
" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/files/file.h" | 9 #include "base/files/file.h" |
| 10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 70 class FileSystemProviderOperationsGetMetadataTest : public testing::Test { | 70 class FileSystemProviderOperationsGetMetadataTest : public testing::Test { |
| 71 protected: | 71 protected: |
| 72 FileSystemProviderOperationsGetMetadataTest() {} | 72 FileSystemProviderOperationsGetMetadataTest() {} |
| 73 virtual ~FileSystemProviderOperationsGetMetadataTest() {} | 73 virtual ~FileSystemProviderOperationsGetMetadataTest() {} |
| 74 | 74 |
| 75 virtual void SetUp() OVERRIDE { | 75 virtual void SetUp() OVERRIDE { |
| 76 file_system_info_ = | 76 file_system_info_ = |
| 77 ProvidedFileSystemInfo(kExtensionId, | 77 ProvidedFileSystemInfo(kExtensionId, |
| 78 kFileSystemId, | 78 kFileSystemId, |
| 79 "" /* display_name */, | 79 "" /* display_name */, |
| 80 false /* writable */, |
| 80 base::FilePath() /* mount_path */); | 81 base::FilePath() /* mount_path */); |
| 81 } | 82 } |
| 82 | 83 |
| 83 ProvidedFileSystemInfo file_system_info_; | 84 ProvidedFileSystemInfo file_system_info_; |
| 84 }; | 85 }; |
| 85 | 86 |
| 86 TEST_F(FileSystemProviderOperationsGetMetadataTest, Execute) { | 87 TEST_F(FileSystemProviderOperationsGetMetadataTest, Execute) { |
| 87 util::LoggingDispatchEventImpl dispatcher(true /* dispatch_reply */); | 88 util::LoggingDispatchEventImpl dispatcher(true /* dispatch_reply */); |
| 88 CallbackLogger callback_logger; | 89 CallbackLogger callback_logger; |
| 89 | 90 |
| (...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 226 base::File::FILE_ERROR_TOO_MANY_OPENED); | 227 base::File::FILE_ERROR_TOO_MANY_OPENED); |
| 227 | 228 |
| 228 ASSERT_EQ(1u, callback_logger.events().size()); | 229 ASSERT_EQ(1u, callback_logger.events().size()); |
| 229 CallbackLogger::Event* event = callback_logger.events()[0]; | 230 CallbackLogger::Event* event = callback_logger.events()[0]; |
| 230 EXPECT_EQ(base::File::FILE_ERROR_TOO_MANY_OPENED, event->result()); | 231 EXPECT_EQ(base::File::FILE_ERROR_TOO_MANY_OPENED, event->result()); |
| 231 } | 232 } |
| 232 | 233 |
| 233 } // namespace operations | 234 } // namespace operations |
| 234 } // namespace file_system_provider | 235 } // namespace file_system_provider |
| 235 } // namespace chromeos | 236 } // namespace chromeos |
| OLD | NEW |