diff options
author | Sascha Roloff <sascha.roloff@huawei.com> | 2022-10-13 11:39:13 +0200 |
---|---|---|
committer | Sascha Roloff <sascha.roloff@huawei.com> | 2022-10-14 12:46:42 +0200 |
commit | f7e4ebf0e2913ff1b987e40baab5c0c809e6c0de (patch) | |
tree | 09ae121b46743a7eb682d9ba1361a59566c558bc /test/buildtool/execution_api/bazel/bazel_execution_client.test.cpp | |
parent | 4d53961509015534fa10a59f4b86a20ae8a66017 (diff) | |
download | justbuild-f7e4ebf0e2913ff1b987e40baab5c0c809e6c0de.tar.gz |
Remove default value of ArtifactDigest::Create template parameter
This enforces the explicit specification, which object type, either file or
tree, should be used to create an artifact digest. This also avoids subtile
errors at locations as in the previous commit, where files as well as trees are
supposed to be handled, but digest creation mistakenly defaults to file object
type.
Diffstat (limited to 'test/buildtool/execution_api/bazel/bazel_execution_client.test.cpp')
-rwxr-xr-x | test/buildtool/execution_api/bazel/bazel_execution_client.test.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/buildtool/execution_api/bazel/bazel_execution_client.test.cpp b/test/buildtool/execution_api/bazel/bazel_execution_client.test.cpp index d5e00ad8..d136e818 100755 --- a/test/buildtool/execution_api/bazel/bazel_execution_client.test.cpp +++ b/test/buildtool/execution_api/bazel/bazel_execution_client.test.cpp @@ -25,8 +25,8 @@ TEST_CASE("Bazel internals: Execution Client", "[execution_api]") { std::string instance_name{"remote-execution"}; std::string content("test"); - auto test_digest = - static_cast<bazel_re::Digest>(ArtifactDigest::Create(content)); + auto test_digest = static_cast<bazel_re::Digest>( + ArtifactDigest::Create<ObjectType::File>(content)); BazelExecutionClient execution_client(info->host, info->port); @@ -93,8 +93,8 @@ TEST_CASE("Bazel internals: Execution Client using env variables", std::string instance_name{"remote-execution"}; std::string content("contents of env variable"); - auto test_digest = - static_cast<bazel_re::Digest>(ArtifactDigest::Create(content)); + auto test_digest = static_cast<bazel_re::Digest>( + ArtifactDigest::Create<ObjectType::File>(content)); BazelExecutionClient execution_client(info->host, info->port); |