| Index: chrome/common/service_process_util_unittest.cc
|
| diff --git a/chrome/common/service_process_util_unittest.cc b/chrome/common/service_process_util_unittest.cc
|
| index 9e4ba36973b8e30615e30daa0b7c38eeadd140c8..188192415f8486a82f6a3024e3689c14de56bdd8 100644
|
| --- a/chrome/common/service_process_util_unittest.cc
|
| +++ b/chrome/common/service_process_util_unittest.cc
|
| @@ -8,8 +8,10 @@
|
| #include "base/bind.h"
|
| #include "base/command_line.h"
|
| #include "base/files/file_path.h"
|
| +#include "base/location.h"
|
| #include "base/process/kill.h"
|
| #include "base/process/launch.h"
|
| +#include "base/single_thread_task_runner.h"
|
| #include "base/strings/string_split.h"
|
|
|
| #if !defined(OS_MACOSX)
|
| @@ -52,7 +54,7 @@ void ShutdownTask(base::MessageLoop* loop) {
|
| // Quit the main message loop.
|
| ASSERT_FALSE(g_good_shutdown);
|
| g_good_shutdown = true;
|
| - loop->PostTask(FROM_HERE, base::MessageLoop::QuitClosure());
|
| + loop->task_runner()->PostTask(FROM_HERE, base::MessageLoop::QuitClosure());
|
| }
|
|
|
| } // namespace
|
| @@ -70,8 +72,8 @@ class ServiceProcessStateTest : public base::MultiProcessTest {
|
| ServiceProcessStateTest();
|
| ~ServiceProcessStateTest() override;
|
| void SetUp() override;
|
| - base::MessageLoopProxy* IOMessageLoopProxy() {
|
| - return io_thread_.message_loop_proxy().get();
|
| + base::SingleThreadTaskRunner* IOMessageLoopProxy() {
|
| + return io_thread_.task_runner().get();
|
| }
|
| void LaunchAndWait(const std::string& name);
|
|
|
| @@ -228,11 +230,11 @@ MULTIPROCESS_TEST_MAIN(ServiceProcessStateTestShutdown) {
|
| ServiceProcessState state;
|
| EXPECT_TRUE(state.Initialize());
|
| EXPECT_TRUE(state.SignalReady(
|
| - io_thread_.message_loop_proxy().get(),
|
| + io_thread_.task_runner().get(),
|
| base::Bind(&ShutdownTask, base::MessageLoop::current())));
|
| - message_loop.PostDelayedTask(FROM_HERE,
|
| - base::MessageLoop::QuitClosure(),
|
| - TestTimeouts::action_max_timeout());
|
| + message_loop.task_runner()->PostDelayedTask(
|
| + FROM_HERE, base::MessageLoop::QuitClosure(),
|
| + TestTimeouts::action_max_timeout());
|
| EXPECT_FALSE(g_good_shutdown);
|
| message_loop.Run();
|
| EXPECT_TRUE(g_good_shutdown);
|
| @@ -274,7 +276,7 @@ class ServiceProcessStateFileManipulationTest : public ::testing::Test {
|
| new Launchd::ScopedInstance(mock_launchd_.get()));
|
| ASSERT_TRUE(service_process_state_.Initialize());
|
| ASSERT_TRUE(service_process_state_.SignalReady(
|
| - io_thread_.message_loop_proxy().get(), base::Closure()));
|
| + io_thread_.task_runner().get(), base::Closure()));
|
| loop_.PostDelayedTask(FROM_HERE,
|
| base::MessageLoop::QuitClosure(),
|
| TestTimeouts::action_max_timeout());
|
| @@ -285,8 +287,8 @@ class ServiceProcessStateFileManipulationTest : public ::testing::Test {
|
| const base::FilePath& bundle_path() const { return bundle_path_; }
|
| const base::FilePath& GetTempDirPath() const { return temp_dir_.path(); }
|
|
|
| - base::MessageLoopProxy* GetIOMessageLoopProxy() {
|
| - return io_thread_.message_loop_proxy().get();
|
| + base::SingleThreadTaskRunner* GetIOMessageLoopProxy() {
|
| + return io_thread_.task_runner().get();
|
| }
|
| void Run() { loop_.Run(); }
|
|
|
|
|