1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-27 12:41:00 +01:00

NarInfoDiskCache: Prepare reproducer for #3898

(cherry picked from commit 2ceece3ef3)
This commit is contained in:
Robert Hensing 2023-01-30 22:15:23 +01:00
parent 80498bd923
commit e404ae5bb6
3 changed files with 95 additions and 0 deletions

View file

@ -207,6 +207,7 @@ public:
if (!cache)
return std::nullopt;
return CacheInfo {
.id = cache->id,
.wantMassQuery = cache->wantMassQuery,
.priority = cache->priority
};
@ -370,4 +371,9 @@ ref<NarInfoDiskCache> getNarInfoDiskCache()
return cache;
}
ref<NarInfoDiskCache> getTestNarInfoDiskCache(Path dbPath)
{
return make_ref<NarInfoDiskCacheImpl>(dbPath);
}
}