From c8394c2ffc3688356cf985d46e8ce56d72050f6a Mon Sep 17 00:00:00 2001 From: Paul Cristian Sarbu Date: Wed, 17 Jul 2024 16:14:12 +0200 Subject: Remove the RetryConfig singleton ...and replace it with instances created early via a builder pattern. --- .../execution_engine/executor/executor.test.cpp | 27 ++++++++++++++-------- 1 file changed, 18 insertions(+), 9 deletions(-) (limited to 'test/buildtool/execution_engine/executor/executor.test.cpp') diff --git a/test/buildtool/execution_engine/executor/executor.test.cpp b/test/buildtool/execution_engine/executor/executor.test.cpp index 5d3a1b6e..c1e8f06a 100644 --- a/test/buildtool/execution_engine/executor/executor.test.cpp +++ b/test/buildtool/execution_engine/executor/executor.test.cpp @@ -283,13 +283,14 @@ TEST_CASE("Executor: Process artifact", "[executor]") { Statistics stats{}; Progress progress{}; Auth auth{}; + RetryConfig retry_config{}; // default retry config Executor runner{&repo_config, api.get(), api.get(), /*properties=*/{}, /*dispatch_list=*/{}, &auth, - &RetryConfig::Instance(), + &retry_config, &stats, &progress}; @@ -304,13 +305,14 @@ TEST_CASE("Executor: Process artifact", "[executor]") { Statistics stats{}; Progress progress{}; Auth auth{}; + RetryConfig retry_config{}; // default retry config Executor runner{&repo_config, api.get(), api.get(), /*properties=*/{}, /*dispatch_list=*/{}, &auth, - &RetryConfig::Instance(), + &retry_config, &stats, &progress}; @@ -325,13 +327,14 @@ TEST_CASE("Executor: Process artifact", "[executor]") { Statistics stats{}; Progress progress{}; Auth auth{}; + RetryConfig retry_config{}; // default retry config Executor runner{&repo_config, api.get(), api.get(), /*properties=*/{}, /*dispatch_list=*/{}, &auth, - &RetryConfig::Instance(), + &retry_config, &stats, &progress}; @@ -367,13 +370,14 @@ TEST_CASE("Executor: Process action", "[executor]") { Statistics stats{}; Progress progress{}; Auth auth{}; + RetryConfig retry_config{}; // default retry config Executor runner{&repo_config, api.get(), api.get(), /*properties=*/{}, /*dispatch_list=*/{}, &auth, - &RetryConfig::Instance(), + &retry_config, &stats, &progress}; @@ -391,13 +395,14 @@ TEST_CASE("Executor: Process action", "[executor]") { Statistics stats{}; Progress progress{}; Auth auth{}; + RetryConfig retry_config{}; // default retry config Executor runner{&repo_config, api.get(), api.get(), /*properties=*/{}, /*dispatch_list=*/{}, &auth, - &RetryConfig::Instance(), + &retry_config, &stats, &progress}; @@ -415,13 +420,14 @@ TEST_CASE("Executor: Process action", "[executor]") { Statistics stats{}; Progress progress{}; Auth auth{}; + RetryConfig retry_config{}; // default retry config Executor runner{&repo_config, api.get(), api.get(), /*properties=*/{}, /*dispatch_list=*/{}, &auth, - &RetryConfig::Instance(), + &retry_config, &stats, &progress}; @@ -442,13 +448,14 @@ TEST_CASE("Executor: Process action", "[executor]") { Statistics stats{}; Progress progress{}; Auth auth{}; + RetryConfig retry_config{}; // default retry config Executor runner{&repo_config, api.get(), api.get(), /*properties=*/{}, /*dispatch_list=*/{}, &auth, - &RetryConfig::Instance(), + &retry_config, &stats, &progress}; @@ -466,13 +473,14 @@ TEST_CASE("Executor: Process action", "[executor]") { Statistics stats{}; Progress progress{}; Auth auth{}; + RetryConfig retry_config{}; // default retry config Executor runner{&repo_config, api.get(), api.get(), /*properties=*/{}, /*dispatch_list=*/{}, &auth, - &RetryConfig::Instance(), + &retry_config, &stats, &progress}; @@ -493,13 +501,14 @@ TEST_CASE("Executor: Process action", "[executor]") { Statistics stats{}; Progress progress{}; Auth auth{}; + RetryConfig retry_config{}; // default retry config Executor runner{&repo_config, api.get(), api.get(), /*properties=*/{}, /*dispatch_list=*/{}, &auth, - &RetryConfig::Instance(), + &retry_config, &stats, &progress}; -- cgit v1.2.3