From 993245d862fcd44b1d8d404b970cbd774526ae2b Mon Sep 17 00:00:00 2001 From: Maksim Denisov Date: Fri, 28 Jun 2024 15:44:16 +0200 Subject: Use StorageConfig with generation for initialization of Storage's generations ...instead of std::filesystem::path. StorageConfig is extended to return paths of Storage's parts. --- test/buildtool/file_system/object_cas.test.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'test/buildtool/file_system/object_cas.test.cpp') diff --git a/test/buildtool/file_system/object_cas.test.cpp b/test/buildtool/file_system/object_cas.test.cpp index 6a809650..2fc0a405 100644 --- a/test/buildtool/file_system/object_cas.test.cpp +++ b/test/buildtool/file_system/object_cas.test.cpp @@ -29,9 +29,10 @@ TEST_CASE_METHOD(HermeticLocalTestFixture, "ObjectCAS", "[file_system]") { std::string test_content{"test"}; auto test_digest = ArtifactDigest::Create(test_content); + auto gen_config = StorageConfig::Instance().CreateGenerationConfig(0); + SECTION("CAS for files") { - ObjectCAS cas{ - StorageConfig::Instance().GenerationCacheDir(0) / "casf"}; + ObjectCAS cas{gen_config.cas_f}; CHECK(not cas.BlobPath(test_digest)); SECTION("Add blob from bytes and verify") { @@ -69,8 +70,7 @@ TEST_CASE_METHOD(HermeticLocalTestFixture, "ObjectCAS", "[file_system]") { } SECTION("CAS for executables") { - ObjectCAS cas{ - StorageConfig::Instance().GenerationCacheDir(0) / "casx"}; + ObjectCAS cas{gen_config.cas_x}; CHECK(not cas.BlobPath(test_digest)); SECTION("Add blob from bytes and verify") { -- cgit v1.2.3