OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 #ifndef NET_DISK_CACHE_DISK_CACHE_TEST_UTIL_H_ | 5 #ifndef NET_DISK_CACHE_DISK_CACHE_TEST_UTIL_H_ |
6 #define NET_DISK_CACHE_DISK_CACHE_TEST_UTIL_H_ | 6 #define NET_DISK_CACHE_DISK_CACHE_TEST_UTIL_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/callback.h" | 11 #include "base/callback_old.h" |
12 #include "base/file_path.h" | 12 #include "base/file_path.h" |
13 #include "base/message_loop.h" | 13 #include "base/message_loop.h" |
14 #include "base/timer.h" | 14 #include "base/timer.h" |
| 15 #include "base/tuple.h" |
15 #include "build/build_config.h" | 16 #include "build/build_config.h" |
16 | 17 |
17 // Re-creates a given test file inside the cache test folder. | 18 // Re-creates a given test file inside the cache test folder. |
18 bool CreateCacheTestFile(const FilePath& name); | 19 bool CreateCacheTestFile(const FilePath& name); |
19 | 20 |
20 // Deletes all file son the cache. | 21 // Deletes all file son the cache. |
21 bool DeleteCache(const FilePath& path); | 22 bool DeleteCache(const FilePath& path); |
22 | 23 |
23 // Copies a set of cache files from the data folder to the test folder. | 24 // Copies a set of cache files from the data folder to the test folder. |
24 bool CopyTestCache(const std::string& name); | 25 bool CopyTestCache(const std::string& name); |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 base::RepeatingTimer<MessageLoopHelper> timer_; | 97 base::RepeatingTimer<MessageLoopHelper> timer_; |
97 int num_callbacks_; | 98 int num_callbacks_; |
98 int num_iterations_; | 99 int num_iterations_; |
99 int last_; | 100 int last_; |
100 bool completed_; | 101 bool completed_; |
101 | 102 |
102 DISALLOW_COPY_AND_ASSIGN(MessageLoopHelper); | 103 DISALLOW_COPY_AND_ASSIGN(MessageLoopHelper); |
103 }; | 104 }; |
104 | 105 |
105 #endif // NET_DISK_CACHE_DISK_CACHE_TEST_UTIL_H_ | 106 #endif // NET_DISK_CACHE_DISK_CACHE_TEST_UTIL_H_ |
OLD | NEW |