Commit 6a022c8d authored by Carlos Caballero's avatar Carlos Caballero Committed by Commit Bot

Use ScopedTaskEnvironment instead of MessageLoop in /chromecast

MessageLoop will go away, eventually.

ScopedTaskEnvironment will per default start a ThreadPool, which should
be fine in most of the cases. If you belive your test needs to make sure
that no ThreadPool runs let me know and I will update the patch.

BUG=891670
This CL was uploaded by git cl split.

R=yucliu@chromium.org

Change-Id: Idbad32ad54c52846e28dbd56841e4c97b8c44fc2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1649170
Auto-Submit: Carlos Caballero <carlscab@google.com>
Reviewed-by: default avatarYuchen Liu <yucliu@chromium.org>
Commit-Queue: Yuchen Liu <yucliu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#667194}
parent d5c16812
......@@ -10,8 +10,8 @@
#include "base/bind.h"
#include "base/bind_helpers.h"
#include "base/callback.h"
#include "base/message_loop/message_loop.h"
#include "base/run_loop.h"
#include "base/test/scoped_task_environment.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
......@@ -50,7 +50,7 @@ class BindToTaskRunnerTest : public ::testing::Test {
public:
~BindToTaskRunnerTest() override { base::RunLoop().RunUntilIdle(); }
base::MessageLoop loop_;
base::test::ScopedTaskEnvironment scoped_task_environment_;
MockCallbacks callbacks_;
};
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment