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

Unified Diff: dbus/mock_unittest.cc

Issue 7745044: Minor cleanups and improvements for the D-Bus library. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 4 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 | « dbus/end_to_end_sync_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dbus/mock_unittest.cc
diff --git a/dbus/mock_unittest.cc b/dbus/mock_unittest.cc
index f0289cfcd1420cfe55b8388f6788fb08010ce826..022b03ded2849f05799b2b33bd23d45fc03b61a7 100644
--- a/dbus/mock_unittest.cc
+++ b/dbus/mock_unittest.cc
@@ -24,7 +24,7 @@ class MockTest : public testing::Test {
MockTest() {
}
- void SetUp() {
+ virtual void SetUp() {
// Create a mock bus.
dbus::Bus::Options options;
options.bus_type = dbus::Bus::SYSTEM;
@@ -52,6 +52,13 @@ class MockTest : public testing::Test {
EXPECT_CALL(*mock_bus_, GetObjectProxy("org.chromium.TestService",
"/org/chromium/TestObject"))
.WillOnce(Return(mock_proxy_.get()));
+
+ // ShutdownAndBlock() will be called in TearDown().
+ EXPECT_CALL(*mock_bus_, ShutdownAndBlock()).WillOnce(Return());
+ }
+
+ virtual void TearDown() {
+ mock_bus_->ShutdownAndBlock();
}
// Called when the response is received.
« no previous file with comments | « dbus/end_to_end_sync_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698