diff options
author | rvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-06-28 19:08:00 +0000 |
---|---|---|
committer | rvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-06-28 19:08:00 +0000 |
commit | 248242a79a708824f5b40816d203c8179e77d85f (patch) | |
tree | e51d268045f5f604cc386f9b3f2d88ed5bf0d268 /net/disk_cache | |
parent | 2b64f7b0cb8c3a1cb9cc8b618a4c9ddaf2af859a (diff) | |
download | chromium_src-248242a79a708824f5b40816d203c8179e77d85f.zip chromium_src-248242a79a708824f5b40816d203c8179e77d85f.tar.gz chromium_src-248242a79a708824f5b40816d203c8179e77d85f.tar.bz2 |
Disk cache: (tests) Make sure that we don't have operations in the
queue when we sleep for a test.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/7275002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@90814 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/disk_cache')
-rw-r--r-- | net/disk_cache/backend_unittest.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/net/disk_cache/backend_unittest.cc b/net/disk_cache/backend_unittest.cc index f1775e1..982a5e5 100644 --- a/net/disk_cache/backend_unittest.cc +++ b/net/disk_cache/backend_unittest.cc @@ -914,6 +914,7 @@ void DiskCacheBackendTest::BackendEnumerations2() { entry1->Close(); ASSERT_EQ(net::OK, CreateEntry(second, &entry2)); entry2->Close(); + FlushQueueForTest(); // Make sure that the timestamp is not the same. base::PlatformThread::Sleep(20); @@ -1091,6 +1092,7 @@ void DiskCacheBackendTest::BackendDoomRecent() { entry->Close(); ASSERT_EQ(net::OK, CreateEntry("second", &entry)); entry->Close(); + FlushQueueForTest(); base::PlatformThread::Sleep(20); Time middle = Time::Now(); @@ -1099,6 +1101,7 @@ void DiskCacheBackendTest::BackendDoomRecent() { entry->Close(); ASSERT_EQ(net::OK, CreateEntry("fourth", &entry)); entry->Close(); + FlushQueueForTest(); base::PlatformThread::Sleep(20); Time final = Time::Now(); @@ -1135,6 +1138,7 @@ void DiskCacheBackendTest::BackendDoomBetween() { disk_cache::Entry *entry; ASSERT_EQ(net::OK, CreateEntry("first", &entry)); entry->Close(); + FlushQueueForTest(); base::PlatformThread::Sleep(20); Time middle_start = Time::Now(); @@ -1143,6 +1147,7 @@ void DiskCacheBackendTest::BackendDoomBetween() { entry->Close(); ASSERT_EQ(net::OK, CreateEntry("third", &entry)); entry->Close(); + FlushQueueForTest(); base::PlatformThread::Sleep(20); Time middle_end = Time::Now(); @@ -1151,6 +1156,7 @@ void DiskCacheBackendTest::BackendDoomBetween() { entry->Close(); ASSERT_EQ(net::OK, OpenEntry("fourth", &entry)); entry->Close(); + FlushQueueForTest(); base::PlatformThread::Sleep(20); Time final = Time::Now(); |