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

Unified Diff: chrome/browser/chromeos/drive/download_handler_unittest.cc

Issue 380993002: Upstream RunBlockingPoolTask(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed. Created 6 years, 5 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 | « no previous file | chrome/browser/chromeos/drive/drive_file_stream_reader_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/drive/download_handler_unittest.cc
diff --git a/chrome/browser/chromeos/drive/download_handler_unittest.cc b/chrome/browser/chromeos/drive/download_handler_unittest.cc
index 012daa369ae61673ca51869def1c6319430737d8..222729c0bad24d84b206550ff4e04290a400d994 100644
--- a/chrome/browser/chromeos/drive/download_handler_unittest.cc
+++ b/chrome/browser/chromeos/drive/download_handler_unittest.cc
@@ -7,11 +7,12 @@
#include "base/files/scoped_temp_dir.h"
#include "chrome/browser/chromeos/drive/dummy_file_system.h"
#include "chrome/browser/chromeos/drive/file_system_util.h"
-#include "chrome/browser/chromeos/drive/test_util.h"
#include "chrome/test/base/testing_profile.h"
#include "content/public/test/mock_download_item.h"
#include "content/public/test/mock_download_manager.h"
#include "content/public/test/test_browser_thread_bundle.h"
+#include "content/public/test/test_utils.h"
+#include "google_apis/drive/test_util.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace drive {
@@ -84,7 +85,7 @@ TEST_F(DownloadHandlerTest, SubstituteDriveDownloadPathNonDrivePath) {
non_drive_path,
&download_item_,
google_apis::test_util::CreateCopyResultCallback(&substituted_path));
- test_util::RunBlockingPoolTask();
+ content::RunAllBlockingPoolTasksUntilIdle();
// Check the result.
EXPECT_EQ(non_drive_path, substituted_path);
@@ -104,7 +105,7 @@ TEST_F(DownloadHandlerTest, SubstituteDriveDownloadPath) {
drive_path,
&download_item_,
google_apis::test_util::CreateCopyResultCallback(&substituted_path));
- test_util::RunBlockingPoolTask();
+ content::RunAllBlockingPoolTasksUntilIdle();
// Check the result.
EXPECT_TRUE(temp_dir_.path().IsParent(substituted_path));
@@ -126,7 +127,7 @@ TEST_F(DownloadHandlerTest, SubstituteDriveDownloadPathGetEntryFailure) {
drive_path,
&download_item_,
google_apis::test_util::CreateCopyResultCallback(&substituted_path));
- test_util::RunBlockingPoolTask();
+ content::RunAllBlockingPoolTasksUntilIdle();
// Check the result.
EXPECT_TRUE(substituted_path.empty());
@@ -145,7 +146,7 @@ TEST_F(DownloadHandlerTest, SubstituteDriveDownloadPathForSavePackage) {
drive_path,
NULL, // DownloadItem is not available at this moment.
google_apis::test_util::CreateCopyResultCallback(&substituted_path));
- test_util::RunBlockingPoolTask();
+ content::RunAllBlockingPoolTasksUntilIdle();
// Check the result of SubstituteDriveDownloadPath().
EXPECT_TRUE(temp_dir_.path().IsParent(substituted_path));
@@ -178,7 +179,7 @@ TEST_F(DownloadHandlerTest, CheckForFileExistence) {
download_handler_->CheckForFileExistence(
&download_item_,
google_apis::test_util::CreateCopyResultCallback(&file_exists));
- test_util::RunBlockingPoolTask();
+ content::RunAllBlockingPoolTasksUntilIdle();
// Check the result.
EXPECT_TRUE(file_exists);
@@ -190,7 +191,7 @@ TEST_F(DownloadHandlerTest, CheckForFileExistence) {
download_handler_->CheckForFileExistence(
&download_item_,
google_apis::test_util::CreateCopyResultCallback(&file_exists));
- test_util::RunBlockingPoolTask();
+ content::RunAllBlockingPoolTasksUntilIdle();
// Check the result.
EXPECT_FALSE(file_exists);
« no previous file with comments | « no previous file | chrome/browser/chromeos/drive/drive_file_stream_reader_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698