diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/buildtool/graph_traverser/TARGETS | 2 | ||||
-rw-r--r-- | test/buildtool/graph_traverser/graph_traverser_remote.test.cpp | 17 |
2 files changed, 13 insertions, 6 deletions
diff --git a/test/buildtool/graph_traverser/TARGETS b/test/buildtool/graph_traverser/TARGETS index f5592f51..d6432a01 100644 --- a/test/buildtool/graph_traverser/TARGETS +++ b/test/buildtool/graph_traverser/TARGETS @@ -59,11 +59,11 @@ , "private-deps": [ "graph_traverser_tests" , ["@", "catch2", "", "catch2"] - , ["@", "src", "src/buildtool/common/remote", "remote_common"] , ["@", "src", "src/buildtool/execution_api/remote", "config"] , ["@", "src", "src/buildtool/file_system", "file_system_manager"] , ["@", "src", "src/buildtool/logging", "log_level"] , ["@", "src", "src/buildtool/logging", "logging"] + , ["@", "src", "src/buildtool/storage", "backend_description"] , ["@", "src", "src/buildtool/storage", "config"] , ["@", "src", "src/buildtool/storage", "storage"] , ["@", "src", "src/utils/cpp", "expected"] diff --git a/test/buildtool/graph_traverser/graph_traverser_remote.test.cpp b/test/buildtool/graph_traverser/graph_traverser_remote.test.cpp index fa1a1e60..f2b2d852 100644 --- a/test/buildtool/graph_traverser/graph_traverser_remote.test.cpp +++ b/test/buildtool/graph_traverser/graph_traverser_remote.test.cpp @@ -15,15 +15,15 @@ #include <cstdlib> #include <filesystem> #include <optional> +#include <string> #include <utility> -#include <vector> #include "catch2/catch_test_macros.hpp" -#include "src/buildtool/common/remote/remote_common.hpp" #include "src/buildtool/execution_api/remote/config.hpp" #include "src/buildtool/file_system/file_system_manager.hpp" #include "src/buildtool/logging/log_level.hpp" #include "src/buildtool/logging/logger.hpp" +#include "src/buildtool/storage/backend_description.hpp" #include "src/buildtool/storage/config.hpp" #include "src/buildtool/storage/storage.hpp" #include "src/utils/cpp/expected.hpp" @@ -43,12 +43,19 @@ std::exit(EXIT_FAILURE); } + auto backend_description = + BackendDescription::Describe(remote_config.remote_address, + remote_config.platform_properties, + remote_config.dispatch); + if (not backend_description) { + Logger::Log(LogLevel::Error, std::move(backend_description).error()); + std::exit(EXIT_FAILURE); + } + StorageConfig::Builder builder; auto config = builder.SetBuildRoot(cache_dir) .SetHashType(TestHashType::ReadFromEnvironment()) - .SetRemoteExecutionArgs(remote_config.remote_address, - remote_config.platform_properties, - remote_config.dispatch) + .SetBackendDescription(*std::move(backend_description)) .Build(); if (not config) { Logger::Log(LogLevel::Error, config.error()); |