From 7eafe5779703275d455558120efc754c2dcc3c01 Mon Sep 17 00:00:00 2001 From: Maksim Denisov Date: Mon, 2 Sep 2024 10:50:48 +0200 Subject: Replace ArtifactDigest::Create ...with ArtifactDigestFactory::HashDataAs --- test/buildtool/execution_api/common/api_test.hpp | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'test/buildtool/execution_api/common/api_test.hpp') diff --git a/test/buildtool/execution_api/common/api_test.hpp b/test/buildtool/execution_api/common/api_test.hpp index b93215a5..382760f6 100644 --- a/test/buildtool/execution_api/common/api_test.hpp +++ b/test/buildtool/execution_api/common/api_test.hpp @@ -24,6 +24,7 @@ #include "catch2/catch_test_macros.hpp" #include "src/buildtool/common/artifact_description.hpp" +#include "src/buildtool/common/artifact_digest_factory.hpp" #include "src/buildtool/compatibility/compatibility.hpp" #include "src/buildtool/crypto/hash_function.hpp" #include "src/buildtool/execution_api/common/execution_action.hpp" @@ -143,8 +144,8 @@ using ExecProps = std::map; ? HashFunction::Type::PlainSHA256 : HashFunction::Type::GitSHA1}; - auto test_digest = - ArtifactDigest::Create(hash_function, test_content); + auto test_digest = ArtifactDigestFactory::HashDataAs( + hash_function, test_content); std::string output_path{"output_file"}; @@ -227,8 +228,8 @@ using ExecProps = std::map; ? HashFunction::Type::PlainSHA256 : HashFunction::Type::GitSHA1}; - auto test_digest = - ArtifactDigest::Create(hash_function, test_content); + auto test_digest = ArtifactDigestFactory::HashDataAs( + hash_function, test_content); auto input_artifact_opt = ArtifactDescription::CreateKnown(test_digest, ObjectType::File) @@ -318,8 +319,8 @@ using ExecProps = std::map; ? HashFunction::Type::PlainSHA256 : HashFunction::Type::GitSHA1}; - auto test_digest = - ArtifactDigest::Create(hash_function, test_content); + auto test_digest = ArtifactDigestFactory::HashDataAs( + hash_function, test_content); std::string output_path{"output_file"}; -- cgit v1.2.3