#ifndef NET_DISK_CACHE_DISK_CACHE_TEST_UTIL_H_
#define NET_DISK_CACHE_DISK_CACHE_TEST_UTIL_H_
#include <stddef.h>
#include <stdint.h>
#include <string>
#include "base/files/file_path.h"
#include "base/memory/raw_ptr.h"
#include "base/memory/scoped_refptr.h"
#include "base/run_loop.h"
#include "base/timer/timer.h"
#include "build/build_config.h"
#include "net/base/test_completion_callback.h"
#include "net/disk_cache/disk_cache.h"
namespace net {
class IOBufferWithSize;
}
bool CreateCacheTestFile(const base::FilePath& name);
bool DeleteCache(const base::FilePath& path);
void CacheTestFillBuffer(char* buffer, size_t len, bool no_nulls);
scoped_refptr<net::IOBufferWithSize> CacheTestCreateAndFillBuffer(
size_t len,
bool no_nulls);
std::string GenerateKey(bool same_length);
bool CheckCacheIntegrity(const base::FilePath& path,
bool new_eviction,
int max_size,
uint32_t mask);
struct BackendResultIsPendingHelper { … };
TestBackendResultCompletionCallbackBase;
class TestBackendResultCompletionCallback
: public TestBackendResultCompletionCallbackBase { … };
struct EntryResultIsPendingHelper { … };
TestEntryResultCompletionCallbackBase;
class TestEntryResultCompletionCallback
: public TestEntryResultCompletionCallbackBase { … };
struct RangeResultIsPendingHelper { … };
class TestRangeResultCompletionCallback
: public net::internal::TestCompletionCallbackTemplate<
disk_cache::RangeResult,
RangeResultIsPendingHelper> { … };
class MessageLoopHelper { … };
class CallbackTest { … };
#endif