summaryrefslogtreecommitdiffstats
path: root/chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc
diff options
context:
space:
mode:
authorsatorux@chromium.org <satorux@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-07 22:51:33 +0000
committersatorux@chromium.org <satorux@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-07 22:51:33 +0000
commit24d4d110ab1ae39c2affba6557bda1ff60e7f947 (patch)
tree59f629cac3c1ea26e200b597acf1169a1b86b10a /chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc
parente2b14e6509e96093dcf5040a2f6ea8563b8abcf5 (diff)
downloadchromium_src-24d4d110ab1ae39c2affba6557bda1ff60e7f947.zip
chromium_src-24d4d110ab1ae39c2affba6557bda1ff60e7f947.tar.gz
chromium_src-24d4d110ab1ae39c2affba6557bda1ff60e7f947.tar.bz2
gdata: Rename *OnIOThreadPool() to *BlockingPool()
The latter is consistent with BrowserThread::GetBlockingPool(). Besides, the term "IO" is infamously confusing in Chrome (you cannot do file operations on IO thread). Along the way, place IsRunningSequenceOnCurrentThread(sequence_token_) in member functions that should be run on the blocking pool. Update comments as well. BUG=none TEST=out/Debug/unit_tests --gtest_filter=GDataFileSystemTest.* Review URL: https://chromiumcodereview.appspot.com/10543064 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@141105 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc')
-rw-r--r--chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc9
1 files changed, 5 insertions, 4 deletions
diff --git a/chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc b/chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc
index 7832fb8..d3b498e 100644
--- a/chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc
+++ b/chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc
@@ -817,7 +817,7 @@ class GDataFileSystemTest : public testing::Test {
}
void PrepareForInitCacheTest() {
- RunAllPendingForIO(); // Allow InitializeCacheOnIOThreadPool to finish.
+ RunAllPendingForIO(); // Allow InitializeCacheOnBlockingPool to finish.
DVLOG(1) << "PrepareForInitCacheTest start";
// Create gdata cache sub directories.
@@ -831,8 +831,8 @@ class GDataFileSystemTest : public testing::Test {
file_system_->cache_paths_[GDataCache::CACHE_TYPE_OUTGOING]));
// Dump some files into cache dirs so that
- // GDataFileSystem::InitializeCacheIOThreadPool would scan through them and
- // populate cache map accordingly.
+ // GDataFileSystem::InitializeCacheOnBlockingPool would scan through them
+ // and populate cache map accordingly.
// Copy files from data dir to cache dir to act as cached files.
for (size_t i = 0; i < ARRAYSIZE_UNSAFE(initial_cache_resources); ++i) {
@@ -885,7 +885,8 @@ class GDataFileSystemTest : public testing::Test {
// OnCacheInitialized() is called again here, which breaks the
// expectation set in SetUp().
file_system_->RemoveObserver(mock_sync_client_.get());
- file_system_->InitializeCacheOnIOThreadPool(); // Force a re-scan.
+ file_system_->RequestInitializeCacheForTesting(); // Force a re-scan.
+ RunAllPendingForIO(); // Wait until the initialization is done.
file_system_->AddObserver(mock_sync_client_.get());
}