diff options
Diffstat (limited to 'zenstore/gc.cpp')
| -rw-r--r-- | zenstore/gc.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/zenstore/gc.cpp b/zenstore/gc.cpp index 8d3b8d018..370c3c965 100644 --- a/zenstore/gc.cpp +++ b/zenstore/gc.cpp @@ -888,7 +888,7 @@ GcScheduler::CollectGarbage(const GcClock::TimePoint& ExpireTime, bool Delete, b #if ZEN_WITH_TESTS -namespace { +namespace gc::impl { static IoBuffer CreateChunk(uint64_t Size) { static std::random_device rd; @@ -909,10 +909,12 @@ namespace { { return CompressedBuffer::Compress(SharedBuffer::MakeView(Buffer.GetData(), Buffer.GetSize())); } -} // namespace +} // namespace gc::impl TEST_CASE("gc.basic") { + using namespace gc::impl; + ScopedTemporaryDirectory TempDir; CidStoreConfiguration CasConfig; @@ -940,6 +942,8 @@ TEST_CASE("gc.basic") TEST_CASE("gc.full") { + using namespace gc::impl; + ScopedTemporaryDirectory TempDir; CidStoreConfiguration CasConfig; @@ -1140,6 +1144,8 @@ TEST_CASE("gc.full") TEST_CASE("gc.diskusagewindow") { + using namespace gc::impl; + DiskUsageWindow Stats; Stats.Append({.SampleTime = 0, .DiskUsage = 0}); // 0 0 Stats.Append({.SampleTime = 10, .DiskUsage = 10}); // 1 10 |