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

Unified Diff: chrome/browser/download/download_target_determiner_unittest.cc

Issue 1143343005: chrome/browser: 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, 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
Index: chrome/browser/download/download_target_determiner_unittest.cc
diff --git a/chrome/browser/download/download_target_determiner_unittest.cc b/chrome/browser/download/download_target_determiner_unittest.cc
index ca91bc39a35afe65492e675ae1e53bb51950bfd7..53812ab44cd80554c8380d329f82789700d6c961 100644
--- a/chrome/browser/download/download_target_determiner_unittest.cc
+++ b/chrome/browser/download/download_target_determiner_unittest.cc
@@ -5,12 +5,14 @@
#include "base/at_exit.h"
#include "base/files/file_path.h"
#include "base/files/scoped_temp_dir.h"
-#include "base/message_loop/message_loop.h"
+#include "base/location.h"
#include "base/observer_list.h"
#include "base/prefs/pref_service.h"
#include "base/run_loop.h"
+#include "base/single_thread_task_runner.h"
#include "base/stl_util.h"
#include "base/strings/string_util.h"
+#include "base/thread_task_runner_handle.h"
#include "base/value_conversions.h"
#include "chrome/browser/download/chrome_download_manager_delegate.h"
#include "chrome/browser/download/download_extensions.h"
@@ -78,12 +80,13 @@ class NullWebContentsDelegate : public content::WebContentsDelegate {
// EXPECT_CALL(mock_fooclass_instance, Foo(callback))
// .WillOnce(ScheduleCallback(false));
ACTION_P(ScheduleCallback, result0) {
- base::MessageLoop::current()->PostTask(FROM_HERE, base::Bind(arg0, result0));
+ base::ThreadTaskRunnerHandle::Get()->PostTask(FROM_HERE,
+ base::Bind(arg0, result0));
}
// Similar to ScheduleCallback, but binds 2 arguments.
ACTION_P2(ScheduleCallback2, result0, result1) {
- base::MessageLoop::current()->PostTask(
+ base::ThreadTaskRunnerHandle::Get()->PostTask(
FROM_HERE, base::Bind(arg0, result0, result1));
}
@@ -376,7 +379,7 @@ void CompletionCallbackWrapper(
scoped_ptr<DownloadTargetInfo>* target_info_receiver,
scoped_ptr<DownloadTargetInfo> target_info) {
target_info_receiver->swap(target_info);
- base::MessageLoop::current()->PostTask(FROM_HERE, closure);
+ base::ThreadTaskRunnerHandle::Get()->PostTask(FROM_HERE, closure);
}
scoped_ptr<DownloadTargetInfo>
« no previous file with comments | « chrome/browser/download/download_target_determiner.cc ('k') | chrome/browser/download/download_test_file_activity_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698