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

Unified Diff: chromeos/dbus/flimflam_service_client_unittest.cc

Issue 10170020: Rework chromeos::FlimflamDevice/ServiceClient with CallMethodWithErrorCallback (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 8 years, 8 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 | « chromeos/dbus/flimflam_service_client.cc ('k') | chromeos/dbus/mock_flimflam_device_client.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/dbus/flimflam_service_client_unittest.cc
diff --git a/chromeos/dbus/flimflam_service_client_unittest.cc b/chromeos/dbus/flimflam_service_client_unittest.cc
index 92b802ed239c7a5b7630abb1d2143f11d7582d30..dafea40903ace9d492c7a1a67e99bb66044c78ff 100644
--- a/chromeos/dbus/flimflam_service_client_unittest.cc
+++ b/chromeos/dbus/flimflam_service_client_unittest.cc
@@ -138,12 +138,17 @@ TEST_F(FlimflamServiceClientTest, Connect) {
scoped_ptr<dbus::Response> response(dbus::Response::CreateEmpty());
// Set expectations.
+ MockClosure mock_closure;
+ MockErrorCallback mock_error_callback;
PrepareForMethodCall(flimflam::kConnectFunction,
base::Bind(&ExpectNoArgument),
response.get());
+ EXPECT_CALL(mock_closure, Run()).Times(1);
// Call method.
client_->Connect(dbus::ObjectPath(kExampleServicePath),
- base::Bind(&ExpectNoResultValue));
+ mock_closure.GetCallback(),
+ mock_error_callback.GetCallback());
+
// Run the message loop.
message_loop_.RunAllPending();
}
« no previous file with comments | « chromeos/dbus/flimflam_service_client.cc ('k') | chromeos/dbus/mock_flimflam_device_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698