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

Unified Diff: dbus/end_to_end_async_unittest.cc

Issue 2211473003: Remove calls to deprecated MessageLoop methods on Windows and Linux. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 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 | « content/shell/browser/shell_browser_main_parts.cc ('k') | dbus/mock_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dbus/end_to_end_async_unittest.cc
diff --git a/dbus/end_to_end_async_unittest.cc b/dbus/end_to_end_async_unittest.cc
index b02b043941882aa0433a0137c321be9f944f9866..2de55c38f6e6f166974ba5daa3452aff52c6eb6a 100644
--- a/dbus/end_to_end_async_unittest.cc
+++ b/dbus/end_to_end_async_unittest.cc
@@ -13,6 +13,7 @@
#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/run_loop.h"
+#include "base/single_thread_task_runner.h"
#include "base/stl_util.h"
#include "base/test/test_timeouts.h"
#include "base/threading/thread.h"
@@ -441,9 +442,8 @@ TEST_F(EndToEndAsyncTest, CancelPendingCalls) {
// We shouldn't receive any responses. Wait for a while just to make sure.
run_loop_.reset(new base::RunLoop);
- message_loop_.PostDelayedTask(FROM_HERE,
- run_loop_->QuitClosure(),
- TestTimeouts::tiny_timeout());
+ message_loop_.task_runner()->PostDelayedTask(
+ FROM_HERE, run_loop_->QuitClosure(), TestTimeouts::tiny_timeout());
run_loop_->Run();
EXPECT_TRUE(response_strings_.empty());
}
@@ -565,9 +565,8 @@ TEST_F(EndToEndAsyncTest, EmptyResponseCallback) {
ObjectProxy::EmptyResponseCallback());
// Post a delayed task to quit the message loop.
run_loop_.reset(new base::RunLoop);
- message_loop_.PostDelayedTask(FROM_HERE,
- run_loop_->QuitClosure(),
- TestTimeouts::tiny_timeout());
+ message_loop_.task_runner()->PostDelayedTask(
+ FROM_HERE, run_loop_->QuitClosure(), TestTimeouts::tiny_timeout());
run_loop_->Run();
// We cannot tell if the empty callback is called, but at least we can
// check if the test does not crash.
« no previous file with comments | « content/shell/browser/shell_browser_main_parts.cc ('k') | dbus/mock_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698