diff options
author | kinaba@chromium.org <kinaba@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-06-20 21:26:12 +0000 |
---|---|---|
committer | kinaba@chromium.org <kinaba@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-06-20 21:26:12 +0000 |
commit | 414c8c855cc752cbb0591bbe1f96b4246cb8460e (patch) | |
tree | 75107ad3fc9743aa9f16608565d88eb7c2bb203b /chrome/browser/google_apis/test_util.cc | |
parent | 63db3609bc41abe699e08bee9f971a7c060d00ca (diff) | |
download | chromium_src-414c8c855cc752cbb0591bbe1f96b4246cb8460e.zip chromium_src-414c8c855cc752cbb0591bbe1f96b4246cb8460e.tar.gz chromium_src-414c8c855cc752cbb0591bbe1f96b4246cb8460e.tar.bz2 |
Use base::RunLoop instead of directly using MessageLoop in Drive related code.
BUG=247559
Review URL: https://chromiumcodereview.appspot.com/17315016
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@207573 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/google_apis/test_util.cc')
-rw-r--r-- | chrome/browser/google_apis/test_util.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/chrome/browser/google_apis/test_util.cc b/chrome/browser/google_apis/test_util.cc index 84dab6c..2e09ea9 100644 --- a/chrome/browser/google_apis/test_util.cc +++ b/chrome/browser/google_apis/test_util.cc @@ -11,6 +11,7 @@ #include "base/path_service.h" #include "base/pending_task.h" #include "base/rand_util.h" +#include "base/run_loop.h" #include "base/strings/string_number_conversions.h" #include "base/strings/string_split.h" #include "base/strings/string_util.h" @@ -79,16 +80,16 @@ void RunBlockingPoolTask() { TaskObserver task_observer; base::MessageLoop::current()->AddTaskObserver(&task_observer); - base::MessageLoop::current()->RunUntilIdle(); + base::RunLoop().RunUntilIdle(); base::MessageLoop::current()->RemoveTaskObserver(&task_observer); if (!task_observer.posted()) break; } } -void RunAndQuit(const base::Closure& closure) { +void RunAndQuit(base::RunLoop* run_loop, const base::Closure& closure) { closure.Run(); - base::MessageLoop::current()->Quit(); + run_loop->Quit(); } bool WriteStringToFile(const base::FilePath& file_path, |