From fd8ad0f561dd253bf7399ce9a4594242e918ca25 Mon Sep 17 00:00:00 2001 From: Maksim Denisov Date: Mon, 27 May 2024 14:57:15 +0200 Subject: Use ArtifactBlobContainer in IExecutionApi ...instead of BazelBlobContainer to not bring bazel_re::Digest to IExecutionApi. --- test/buildtool/execution_engine/executor/executor.test.cpp | 2 +- test/buildtool/execution_engine/executor/executor_api.test.hpp | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'test/buildtool/execution_engine/executor') diff --git a/test/buildtool/execution_engine/executor/executor.test.cpp b/test/buildtool/execution_engine/executor/executor.test.cpp index 7a09dc84..69e06df9 100644 --- a/test/buildtool/execution_engine/executor/executor.test.cpp +++ b/test/buildtool/execution_engine/executor/executor.test.cpp @@ -174,7 +174,7 @@ class TestApi : public IExecutionApi { -> std::optional override { return std::nullopt; // not needed by Executor } - auto Upload(BazelBlobContainer const& blobs, bool /*unused*/) noexcept + auto Upload(ArtifactBlobContainer&& blobs, bool /*unused*/) noexcept -> bool final { auto blob_range = blobs.Blobs(); return std::all_of( diff --git a/test/buildtool/execution_engine/executor/executor_api.test.hpp b/test/buildtool/execution_engine/executor/executor_api.test.hpp index c8ec19d7..8c3c84ca 100644 --- a/test/buildtool/execution_engine/executor/executor_api.test.hpp +++ b/test/buildtool/execution_engine/executor/executor_api.test.hpp @@ -51,7 +51,7 @@ static inline void RunBlobUpload(RepositoryConfig* repo_config, SetupConfig(repo_config); auto api = factory(); std::string const blob = "test"; - CHECK(api->Upload(BazelBlobContainer{{BazelBlob{ + CHECK(api->Upload(ArtifactBlobContainer{{ArtifactBlob{ ArtifactDigest{HashFunction::ComputeBlobHash(blob).HexString(), blob.size(), /*is_tree=*/false}, @@ -382,9 +382,9 @@ static inline void TestUploadAndDownloadTrees( // upload blobs auto api = factory(); - REQUIRE(api->Upload( - BazelBlobContainer{{BazelBlob{foo_digest, foo, /*is_exec=*/false}, - BazelBlob{bar_digest, bar, /*is_exec=*/false}}})); + REQUIRE(api->Upload(ArtifactBlobContainer{ + {ArtifactBlob{foo_digest, foo, /*is_exec=*/false}, + ArtifactBlob{bar_digest, bar, /*is_exec=*/false}}})); // define known artifacts auto foo_desc = ArtifactDescription{foo_digest, ObjectType::File}; -- cgit v1.2.3