| Index: net/disk_cache/backend_unittest.cc
|
| diff --git a/net/disk_cache/backend_unittest.cc b/net/disk_cache/backend_unittest.cc
|
| index 275f1a96a3d34b4c688143c06fddcb249556baf8..605c6f453666542c1f44a9293bb98f0ee53c8a96 100644
|
| --- a/net/disk_cache/backend_unittest.cc
|
| +++ b/net/disk_cache/backend_unittest.cc
|
| @@ -2899,6 +2899,13 @@ TEST_F(DiskCacheBackendTest, SimpleCacheOpenMissingFile) {
|
| entry->Close();
|
| entry = NULL;
|
|
|
| + // To make sure the file creation completed we need to call open again so that
|
| + // we block until it actually created the files.
|
| + ASSERT_EQ(net::OK, OpenEntry(key, &entry));
|
| + ASSERT_TRUE(entry != NULL);
|
| + entry->Close();
|
| + entry = NULL;
|
| +
|
| // Delete one of the files in the entry.
|
| base::FilePath to_delete_file = cache_path_.AppendASCII(
|
| disk_cache::simple_util::GetFilenameFromKeyAndIndex(key, 0));
|
| @@ -2930,6 +2937,13 @@ TEST_F(DiskCacheBackendTest, SimpleCacheOpenBadFile) {
|
| entry->Close();
|
| entry = NULL;
|
|
|
| + // To make sure the file creation completed we need to call open again so that
|
| + // we block until it actually created the files.
|
| + ASSERT_EQ(net::OK, OpenEntry(key, &entry));
|
| + ASSERT_NE(null, entry);
|
| + entry->Close();
|
| + entry = NULL;
|
| +
|
| // Write an invalid header on stream 1.
|
| base::FilePath entry_file1_path = cache_path_.AppendASCII(
|
| disk_cache::simple_util::GetFilenameFromKeyAndIndex(key, 1));
|
|
|