OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "base/basictypes.h" | 5 #include "base/basictypes.h" |
6 #include "base/file_util.h" | 6 #include "base/file_util.h" |
7 #include "base/port.h" | 7 #include "base/port.h" |
8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
9 #include "base/stringprintf.h" | 9 #include "base/stringprintf.h" |
10 #include "base/third_party/dynamic_annotations/dynamic_annotations.h" | 10 #include "base/third_party/dynamic_annotations/dynamic_annotations.h" |
(...skipping 2883 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2894 header.initial_magic_number = GG_UINT64_C(0xbadf00d); | 2894 header.initial_magic_number = GG_UINT64_C(0xbadf00d); |
2895 EXPECT_EQ( | 2895 EXPECT_EQ( |
2896 implicit_cast<int>(sizeof(header)), | 2896 implicit_cast<int>(sizeof(header)), |
2897 file_util::WriteFile(entry_file1_path, reinterpret_cast<char*>(&header), | 2897 file_util::WriteFile(entry_file1_path, reinterpret_cast<char*>(&header), |
2898 sizeof(header))); | 2898 sizeof(header))); |
2899 ASSERT_EQ(net::ERR_FAILED, OpenEntry(key, &entry)); | 2899 ASSERT_EQ(net::ERR_FAILED, OpenEntry(key, &entry)); |
2900 } | 2900 } |
2901 | 2901 |
2902 TEST_F(DiskCacheBackendTest, SimpleDoomRecent) { | 2902 TEST_F(DiskCacheBackendTest, SimpleDoomRecent) { |
2903 SetSimpleCacheMode(); | 2903 SetSimpleCacheMode(); |
2904 InitCache(); | |
2905 BackendDoomRecent(); | 2904 BackendDoomRecent(); |
2906 } | 2905 } |
2907 | 2906 |
2908 TEST_F(DiskCacheBackendTest, SimpleDoomBetween) { | 2907 TEST_F(DiskCacheBackendTest, SimpleDoomBetween) { |
2909 SetSimpleCacheMode(); | 2908 SetSimpleCacheMode(); |
2910 InitCache(); | |
2911 BackendDoomBetween(); | 2909 BackendDoomBetween(); |
2912 } | 2910 } |
2913 | 2911 |
2914 #endif // !defined(OS_WIN) | 2912 #endif // !defined(OS_WIN) |
OLD | NEW |