From e3028f4c2fbf34e1fd2ecc675b7533f03043fa3b Mon Sep 17 00:00:00 2001 From: Alberto Sartori Date: Mon, 9 May 2022 10:59:45 +0200 Subject: allow for run tests in compatibility mode --- test/utils/remote_execution/main-remote-execution.cpp | 5 +++++ 1 file changed, 5 insertions(+) mode change 100755 => 100644 test/utils/remote_execution/main-remote-execution.cpp (limited to 'test/utils/remote_execution/main-remote-execution.cpp') diff --git a/test/utils/remote_execution/main-remote-execution.cpp b/test/utils/remote_execution/main-remote-execution.cpp old mode 100755 new mode 100644 index 3f435dcc..4db1d690 --- a/test/utils/remote_execution/main-remote-execution.cpp +++ b/test/utils/remote_execution/main-remote-execution.cpp @@ -6,6 +6,7 @@ #include #include "catch2/catch.hpp" +#include "src/buildtool/compatibility/compatibility.hpp" #include "src/buildtool/execution_api/remote/config.hpp" #include "test/utils/logging/log_config.hpp" #include "test/utils/test_env.hpp" @@ -21,6 +22,10 @@ void wait_for_grpc_to_shutdown() { /// environment variable is malformed, we write a message and stop execution. /// \returns true If remote execution was successfully configured. [[nodiscard]] auto ConfigureRemoteExecution() -> bool { + ReadCompatibilityFromEnv(); + if (Compatibility::IsCompatible()) { + HashGenerator::SetHashGenerator(HashGenerator::HashType::SHA256); + } auto address = ReadRemoteAddressFromEnv(); auto& config = RemoteExecutionConfig::Instance(); if (address and not config.SetAddress(*address)) { -- cgit v1.2.3