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

Unified Diff: chrome/test/base/tracing_browsertest.cc

Issue 1167163002: chrome: Remove use of MessageLoopProxy and deprecated MessageLoop APIs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added some missing message_loop.h includes. 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 | « chrome/test/base/testing_profile.cc ('k') | chrome/test/base/view_event_test_base.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/base/tracing_browsertest.cc
diff --git a/chrome/test/base/tracing_browsertest.cc b/chrome/test/base/tracing_browsertest.cc
index e6128a3c4c32b387545a0ba23cb86827826efe3c..3ebc61052c7d0359fc498c76ca49a0fb674810d2 100644
--- a/chrome/test/base/tracing_browsertest.cc
+++ b/chrome/test/base/tracing_browsertest.cc
@@ -4,8 +4,10 @@
#include "chrome/test/base/tracing.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/thread_task_runner_handle.h"
#include "base/trace_event/trace_event.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h"
@@ -56,7 +58,8 @@ IN_PROC_BROWSER_TEST_F(TracingBrowserTest, BeginTracingWithWatch) {
// One event after wait.
ASSERT_TRUE(BeginTracingWithWatch(g_category, g_category, g_event, 1));
- base::MessageLoop::current()->PostTask(FROM_HERE, base::Bind(&AddEvents, 1));
+ base::ThreadTaskRunnerHandle::Get()->PostTask(FROM_HERE,
+ base::Bind(&AddEvents, 1));
EXPECT_TRUE(WaitForWatchEvent(no_timeout));
ASSERT_TRUE(EndTracing(&json_events));
@@ -74,7 +77,8 @@ IN_PROC_BROWSER_TEST_F(TracingBrowserTest, BeginTracingWithWatch) {
// Multi event after wait.
ASSERT_TRUE(BeginTracingWithWatch(g_category, g_category, g_event, 5));
- base::MessageLoop::current()->PostTask(FROM_HERE, base::Bind(&AddEvents, 5));
+ base::ThreadTaskRunnerHandle::Get()->PostTask(FROM_HERE,
+ base::Bind(&AddEvents, 5));
EXPECT_TRUE(WaitForWatchEvent(no_timeout));
ASSERT_TRUE(EndTracing(&json_events));
« no previous file with comments | « chrome/test/base/testing_profile.cc ('k') | chrome/test/base/view_event_test_base.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698