Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Unified Diff: trunk/src/chrome/browser/extensions/api/image_writer_private/destroy_partitions_operation_unittest.cc

Issue 384513002: Revert 282130 "Adds API test for imageWriterPrivate.writeFromFile" (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | trunk/src/chrome/browser/extensions/api/image_writer_private/image_writer_private_apitest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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
« no previous file with comments | « no previous file | trunk/src/chrome/browser/extensions/api/image_writer_private/image_writer_private_apitest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698