| Index: chrome/browser/chromeos/file_system_provider/operations/read_directory_unittest.cc
|
| diff --git a/chrome/browser/chromeos/file_system_provider/operations/read_directory_unittest.cc b/chrome/browser/chromeos/file_system_provider/operations/read_directory_unittest.cc
|
| index f4152831bc3b7b77f89fabf308cfe0f044c16771..7fb0a1397cc238a9603bb029e2fbb366a01400da 100644
|
| --- a/chrome/browser/chromeos/file_system_provider/operations/read_directory_unittest.cc
|
| +++ b/chrome/browser/chromeos/file_system_provider/operations/read_directory_unittest.cc
|
| @@ -92,6 +92,8 @@ class FileSystemProviderOperationsReadDirectoryTest : public testing::Test {
|
| };
|
|
|
| TEST_F(FileSystemProviderOperationsReadDirectoryTest, Execute) {
|
| + using extensions::api::file_system_provider::ReadDirectoryRequestedOptions;
|
| +
|
| util::LoggingDispatchEventImpl dispatcher(true /* dispatch_reply */);
|
| CallbackLogger callback_logger;
|
|
|
| @@ -114,20 +116,15 @@ TEST_F(FileSystemProviderOperationsReadDirectoryTest, Execute) {
|
| base::ListValue* event_args = event->event_args.get();
|
| ASSERT_EQ(1u, event_args->GetSize());
|
|
|
| - base::DictionaryValue* options = NULL;
|
| - ASSERT_TRUE(event_args->GetDictionary(0, &options));
|
| -
|
| - std::string event_file_system_id;
|
| - EXPECT_TRUE(options->GetString("fileSystemId", &event_file_system_id));
|
| - EXPECT_EQ(kFileSystemId, event_file_system_id);
|
| -
|
| - int event_request_id = -1;
|
| - EXPECT_TRUE(options->GetInteger("requestId", &event_request_id));
|
| - EXPECT_EQ(kRequestId, event_request_id);
|
| + const base::DictionaryValue* options_as_value = NULL;
|
| + ASSERT_TRUE(event_args->GetDictionary(0, &options_as_value));
|
|
|
| - std::string event_directory_path;
|
| - EXPECT_TRUE(options->GetString("directoryPath", &event_directory_path));
|
| - EXPECT_EQ(kDirectoryPath, event_directory_path);
|
| + ReadDirectoryRequestedOptions options;
|
| + ASSERT_TRUE(
|
| + ReadDirectoryRequestedOptions::Populate(*options_as_value, &options));
|
| + EXPECT_EQ(kFileSystemId, options.file_system_id);
|
| + EXPECT_EQ(kRequestId, options.request_id);
|
| + EXPECT_EQ(kDirectoryPath, options.directory_path);
|
| }
|
|
|
| TEST_F(FileSystemProviderOperationsReadDirectoryTest, Execute_NoListener) {
|
|
|