| Index: trunk/src/chrome/browser/extensions/api/image_writer_private/destroy_partitions_operation_unittest.cc
|
| ===================================================================
|
| --- trunk/src/chrome/browser/extensions/api/image_writer_private/destroy_partitions_operation_unittest.cc (revision 282139)
|
| +++ trunk/src/chrome/browser/extensions/api/image_writer_private/destroy_partitions_operation_unittest.cc (working copy)
|
| @@ -22,13 +22,17 @@
|
| TEST_F(ImageWriterDestroyPartitionsOperationTest, EndToEnd) {
|
| TestingProfile profile;
|
| MockOperationManager manager(&profile);
|
| + scoped_refptr<FakeImageWriterClient> client = FakeImageWriterClient::Create();
|
|
|
| scoped_refptr<DestroyPartitionsOperation> operation(
|
| - new DestroyPartitionsOperation(
|
| - manager.AsWeakPtr(),
|
| - kDummyExtensionId,
|
| - test_utils_.GetDevicePath().AsUTF8Unsafe()));
|
| + new DestroyPartitionsOperation(manager.AsWeakPtr(),
|
| + kDummyExtensionId,
|
| + test_device_path_.AsUTF8Unsafe()));
|
|
|
| +#if !defined(OS_CHROMEOS)
|
| + operation->SetUtilityClientForTesting(client);
|
| +#endif
|
| +
|
| EXPECT_CALL(
|
| manager,
|
| OnProgress(kDummyExtensionId, image_writer_api::STAGE_VERIFYWRITE, _))
|
| @@ -50,10 +54,10 @@
|
| base::RunLoop().RunUntilIdle();
|
|
|
| #if !defined(OS_CHROMEOS)
|
| - test_utils_.GetUtilityClient()->Progress(0);
|
| - test_utils_.GetUtilityClient()->Progress(50);
|
| - test_utils_.GetUtilityClient()->Progress(100);
|
| - test_utils_.GetUtilityClient()->Success();
|
| + client->Progress(0);
|
| + client->Progress(50);
|
| + client->Progress(100);
|
| + client->Success();
|
|
|
| base::RunLoop().RunUntilIdle();
|
| #endif
|
|
|