diff options
Diffstat (limited to 'test/buildtool/execution_engine/executor')
-rwxr-xr-x | test/buildtool/execution_engine/executor/executor.test.cpp | 12 | ||||
-rwxr-xr-x | test/buildtool/execution_engine/executor/executor_api.test.hpp | 15 |
2 files changed, 17 insertions, 10 deletions
diff --git a/test/buildtool/execution_engine/executor/executor.test.cpp b/test/buildtool/execution_engine/executor/executor.test.cpp index 3e56909e..e055dfd7 100755 --- a/test/buildtool/execution_engine/executor/executor.test.cpp +++ b/test/buildtool/execution_engine/executor/executor.test.cpp @@ -63,9 +63,11 @@ class TestResponse : public IExecutionResponse { // collect files and store them for (auto const& path : config_.execution.outputs) { try { - artifacts.emplace(path, - Artifact::ObjectInfo{ArtifactDigest{path, 0}, - ObjectType::File}); + artifacts.emplace( + path, + Artifact::ObjectInfo{ + ArtifactDigest{path, 0, /*is_tree=*/false}, + ObjectType::File}); } catch (...) { return {}; } @@ -170,8 +172,8 @@ static void SetupConfig(std::filesystem::path const& ws) { SetupConfig(ws); auto const local_cpp_desc = ArtifactDescription{path{"local.cpp"}, ""}; - auto const known_cpp_desc = - ArtifactDescription{ArtifactDigest{"known.cpp", 0}, ObjectType::File}; + auto const known_cpp_desc = ArtifactDescription{ + ArtifactDigest{"known.cpp", 0, /*is_tree=*/false}, ObjectType::File}; auto const test_action_desc = ActionDescription{ {"output1.exe", "output2.exe"}, diff --git a/test/buildtool/execution_engine/executor/executor_api.test.hpp b/test/buildtool/execution_engine/executor/executor_api.test.hpp index d1b13ee5..4fe06aa1 100755 --- a/test/buildtool/execution_engine/executor/executor_api.test.hpp +++ b/test/buildtool/execution_engine/executor/executor_api.test.hpp @@ -28,7 +28,8 @@ static inline void RunBlobUpload(ApiFactory const& factory) { std::string const blob = "test"; CHECK(api->Upload(BlobContainer{{BazelBlob{ ArtifactDigest{HashFunction::ComputeBlobHash(blob).HexString(), - blob.size()}, + blob.size(), + /*is_tree=*/false}, blob}}})); } @@ -273,10 +274,14 @@ static inline void TestUploadAndDownloadTrees(ApiFactory const& factory, auto foo = std::string{"foo"}; auto bar = std::string{"bar"}; - auto foo_digest = ArtifactDigest{ - HashFunction::ComputeBlobHash(foo).HexString(), foo.size()}; - auto bar_digest = ArtifactDigest{ - HashFunction::ComputeBlobHash(bar).HexString(), bar.size()}; + auto foo_digest = + ArtifactDigest{HashFunction::ComputeBlobHash(foo).HexString(), + foo.size(), + /*is_tree=*/false}; + auto bar_digest = + ArtifactDigest{HashFunction::ComputeBlobHash(bar).HexString(), + bar.size(), + /*is_tree=*/false}; // upload blobs auto api = factory(); |