summaryrefslogtreecommitdiff
path: root/test/buildtool/file_system/git_tree.test.cpp
diff options
context:
space:
mode:
authorMaksim Denisov <denisov.maksim@huawei.com>2024-08-29 09:18:09 +0200
committerMaksim Denisov <denisov.maksim@huawei.com>2024-08-30 17:17:09 +0200
commitdd12fcb5eea5970ac8ef6acd7a200c1e92ce81ea (patch)
tree1d7fcfb366f45ca11a908ecc90f3f55d4c2e6618 /test/buildtool/file_system/git_tree.test.cpp
parent98884d6d3f5c31efb3390ab75f1952dcdff0221c (diff)
downloadjustbuild-dd12fcb5eea5970ac8ef6acd7a200c1e92ce81ea.tar.gz
Replace bazel_re::Digest in GitRepo::SymlinksCheckFunc callback
...with ArtifactDigest.
Diffstat (limited to 'test/buildtool/file_system/git_tree.test.cpp')
-rw-r--r--test/buildtool/file_system/git_tree.test.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/test/buildtool/file_system/git_tree.test.cpp b/test/buildtool/file_system/git_tree.test.cpp
index f2cff0ba..c8a0b14d 100644
--- a/test/buildtool/file_system/git_tree.test.cpp
+++ b/test/buildtool/file_system/git_tree.test.cpp
@@ -27,7 +27,6 @@
#include "catch2/catch_test_macros.hpp"
#include "fmt/core.h"
#include "src/buildtool/common/artifact_digest.hpp"
-#include "src/buildtool/common/bazel_types.hpp"
#include "src/buildtool/file_system/file_system_manager.hpp"
#include "src/buildtool/file_system/git_cas.hpp"
#include "src/buildtool/file_system/git_repo.hpp"
@@ -106,11 +105,10 @@ class SymlinksChecker final {
: cas_{*cas} {}
[[nodiscard]] auto operator()(
- std::vector<bazel_re::Digest> const& ids) const noexcept -> bool {
+ std::vector<ArtifactDigest> const& ids) const noexcept -> bool {
return std::all_of(
- ids.begin(), ids.end(), [&cas = cas_](bazel_re::Digest const& id) {
- auto content = cas.ReadObject(ArtifactDigest(id).hash(),
- /*is_hex_id=*/true);
+ ids.begin(), ids.end(), [&cas = cas_](ArtifactDigest const& id) {
+ auto content = cas.ReadObject(id.hash(), /*is_hex_id=*/true);
return content.has_value() and PathIsNonUpwards(*content);
});
};