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

Unified Diff: content/public/test/test_utils.cc

Issue 1159623009: content: Remove use of MessageLoopProxy and deprecated MessageLoop APIs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Test build fix. Created 5 years, 6 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/public/test/test_file_system_context.cc ('k') | content/shell/browser/blink_test_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/test/test_utils.cc
diff --git a/content/public/test/test_utils.cc b/content/public/test/test_utils.cc
index 2fa45c0b10744d8f7b3f63c4f79243d523b39316..4293f399d97612ea632965f0f2df7cebb3fee947 100644
--- a/content/public/test/test_utils.cc
+++ b/content/public/test/test_utils.cc
@@ -5,9 +5,11 @@
#include "content/public/test/test_utils.h"
#include "base/bind.h"
-#include "base/message_loop/message_loop.h"
+#include "base/location.h"
#include "base/run_loop.h"
+#include "base/single_thread_task_runner.h"
#include "base/strings/utf_string_conversions.h"
+#include "base/thread_task_runner_handle.h"
#include "base/values.h"
#include "content/public/browser/browser_child_process_host_iterator.h"
#include "content/public/browser/notification_service.h"
@@ -37,7 +39,7 @@ static void DeferredQuitRunLoop(const base::Closure& quit_task,
if (num_quit_deferrals <= 0) {
quit_task.Run();
} else {
- base::MessageLoop::current()->PostTask(
+ base::ThreadTaskRunnerHandle::Get()->PostTask(
FROM_HERE,
base::Bind(&DeferredQuitRunLoop, quit_task, num_quit_deferrals - 1));
}
@@ -127,8 +129,8 @@ void RunThisRunLoop(base::RunLoop* run_loop) {
void RunAllPendingInMessageLoop() {
base::RunLoop run_loop;
- base::MessageLoop::current()->PostTask(
- FROM_HERE, GetQuitTaskForRunLoop(&run_loop));
+ base::ThreadTaskRunnerHandle::Get()->PostTask(
+ FROM_HERE, GetQuitTaskForRunLoop(&run_loop));
RunThisRunLoop(&run_loop);
}
« no previous file with comments | « content/public/test/test_file_system_context.cc ('k') | content/shell/browser/blink_test_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698