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

Unified Diff: ipc/sync_socket_unittest.cc

Issue 1127153003: ipc: Remove use of MessageLoopProxy and deprecated MessageLoop APIs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. Created 5 years, 7 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 | « ipc/mojo/ipc_message_pipe_reader.cc ('k') | ipc/unix_domain_socket_util_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ipc/sync_socket_unittest.cc
diff --git a/ipc/sync_socket_unittest.cc b/ipc/sync_socket_unittest.cc
index 238f2a889b7fd69376a8aa657d89baa88a7731bf..82ab0cd0992af7721f2e3037e0aca191d9649017 100644
--- a/ipc/sync_socket_unittest.cc
+++ b/ipc/sync_socket_unittest.cc
@@ -5,11 +5,12 @@
#include "base/sync_socket.h"
#include <stdio.h>
-#include <string>
#include <sstream>
+#include <string>
#include "base/bind.h"
-#include "base/message_loop/message_loop.h"
+#include "base/location.h"
+#include "base/single_thread_task_runner.h"
#include "base/threading/thread.h"
#include "ipc/ipc_test_base.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -227,7 +228,8 @@ TEST_F(SyncSocketTest, DisconnectTest) {
// Try to do a blocking read from one of the sockets on the worker thread.
char buf[0xff];
size_t received = 1U; // Initialize to an unexpected value.
- worker.message_loop()->PostTask(FROM_HERE,
+ worker.task_runner()->PostTask(
+ FROM_HERE,
base::Bind(&BlockingRead, &pair[0], &buf[0], arraysize(buf), &received));
// Wait for the worker thread to say hello.
@@ -257,9 +259,9 @@ TEST_F(SyncSocketTest, BlockingReceiveTest) {
// Try to do a blocking read from one of the sockets on the worker thread.
char buf[kHelloStringLength] = {0};
size_t received = 1U; // Initialize to an unexpected value.
- worker.message_loop()->PostTask(FROM_HERE,
- base::Bind(&BlockingRead, &pair[0], &buf[0],
- kHelloStringLength, &received));
+ worker.task_runner()->PostTask(FROM_HERE,
+ base::Bind(&BlockingRead, &pair[0], &buf[0],
+ kHelloStringLength, &received));
// Wait for the worker thread to say hello.
char hello[kHelloStringLength] = {0};
« no previous file with comments | « ipc/mojo/ipc_message_pipe_reader.cc ('k') | ipc/unix_domain_socket_util_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698