| Index: chrome/browser/chromeos/file_system_provider/operations/move_entry_unittest.cc
|
| diff --git a/chrome/browser/chromeos/file_system_provider/operations/move_entry_unittest.cc b/chrome/browser/chromeos/file_system_provider/operations/move_entry_unittest.cc
|
| index 857cbf4fbb35fc91b083b32e7c81448c16290566..d1008ea815ef7271d3cdebb6d711a2eda58dacc5 100644
|
| --- a/chrome/browser/chromeos/file_system_provider/operations/move_entry_unittest.cc
|
| +++ b/chrome/browser/chromeos/file_system_provider/operations/move_entry_unittest.cc
|
| @@ -50,6 +50,8 @@ class FileSystemProviderOperationsMoveEntryTest : public testing::Test {
|
| };
|
|
|
| TEST_F(FileSystemProviderOperationsMoveEntryTest, Execute) {
|
| + using extensions::api::file_system_provider::MoveEntryRequestedOptions;
|
| +
|
| util::LoggingDispatchEventImpl dispatcher(true /* dispatch_reply */);
|
| util::StatusCallbackLog callback_log;
|
|
|
| @@ -72,24 +74,15 @@ TEST_F(FileSystemProviderOperationsMoveEntryTest, 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);
|
| -
|
| - std::string event_source_path;
|
| - EXPECT_TRUE(options->GetString("sourcePath", &event_source_path));
|
| - EXPECT_EQ(kSourcePath, event_source_path);
|
| + const base::DictionaryValue* options_as_value = NULL;
|
| + ASSERT_TRUE(event_args->GetDictionary(0, &options_as_value));
|
|
|
| - std::string event_target_path;
|
| - EXPECT_TRUE(options->GetString("targetPath", &event_target_path));
|
| - EXPECT_EQ(kTargetPath, event_target_path);
|
| + MoveEntryRequestedOptions options;
|
| + ASSERT_TRUE(MoveEntryRequestedOptions::Populate(*options_as_value, &options));
|
| + EXPECT_EQ(kFileSystemId, options.file_system_id);
|
| + EXPECT_EQ(kRequestId, options.request_id);
|
| + EXPECT_EQ(kSourcePath, options.source_path);
|
| + EXPECT_EQ(kTargetPath, options.target_path);
|
| }
|
|
|
| TEST_F(FileSystemProviderOperationsMoveEntryTest, Execute_NoListener) {
|
|
|