diff options
author | Maksim Denisov <denisov.maksim@huawei.com> | 2024-08-28 14:43:23 +0200 |
---|---|---|
committer | Maksim Denisov <denisov.maksim@huawei.com> | 2024-09-09 13:07:13 +0200 |
commit | 50bcabb0717dae7c8411db59115c41b7cc636cb3 (patch) | |
tree | 1c91538e21a6ad6a723c37909d5746ca5217af4a /test/buildtool/storage/local_cas.test.cpp | |
parent | 1afa257e0f808f670c1ea87983bf76db89c63124 (diff) | |
download | justbuild-50bcabb0717dae7c8411db59115c41b7cc636cb3.tar.gz |
Replace ArtifactDigest::CreateFromFile
...with ArtifactDigestFactory::HashFileAs
Diffstat (limited to 'test/buildtool/storage/local_cas.test.cpp')
-rw-r--r-- | test/buildtool/storage/local_cas.test.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/test/buildtool/storage/local_cas.test.cpp b/test/buildtool/storage/local_cas.test.cpp index 4b7c844a..44371fea 100644 --- a/test/buildtool/storage/local_cas.test.cpp +++ b/test/buildtool/storage/local_cas.test.cpp @@ -17,6 +17,7 @@ #include "catch2/catch_test_macros.hpp" #include "src/buildtool/common/artifact_digest.hpp" +#include "src/buildtool/common/artifact_digest_factory.hpp" #include "src/buildtool/execution_api/bazel_msg/bazel_blob_container.hpp" #include "src/buildtool/file_system/file_system_manager.hpp" #include "src/buildtool/file_system/object_type.hpp" @@ -82,7 +83,7 @@ TEST_CASE("LocalCAS: Add blob to storage from non-executable file", std::filesystem::path non_exec_file{ "test/buildtool/storage/data/non_executable_file"}; - auto test_blob = ArtifactDigest::CreateFromFile<ObjectType::File>( + auto test_blob = ArtifactDigestFactory::HashFileAs<ObjectType::File>( storage_config.Get().hash_function, non_exec_file); REQUIRE(test_blob); @@ -133,7 +134,7 @@ TEST_CASE("LocalCAS: Add blob to storage from executable file", "[storage]") { std::filesystem::path exec_file{ "test/buildtool/storage/data/executable_file"}; - auto test_blob = ArtifactDigest::CreateFromFile<ObjectType::File>( + auto test_blob = ArtifactDigestFactory::HashFileAs<ObjectType::File>( storage_config.Get().hash_function, exec_file); REQUIRE(test_blob); |