From 2a31d8552e26f9a257e3c6eba877ac092b04dee9 Mon Sep 17 00:00:00 2001 From: Luke Parker Date: Sat, 23 Mar 2024 16:48:12 -0400 Subject: [PATCH] Add empty string for the KEY to serai-client to use the default keystore --- substrate/client/tests/common/mod.rs | 7 ++++++- substrate/client/tests/dht.rs | 4 +++- substrate/client/tests/validator_sets.rs | 5 ++++- 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/substrate/client/tests/common/mod.rs b/substrate/client/tests/common/mod.rs index d887b0b1..a6d5300b 100644 --- a/substrate/client/tests/common/mod.rs +++ b/substrate/client/tests/common/mod.rs @@ -29,7 +29,12 @@ macro_rules! serai_test { "--rpc-cors".to_string(), "all".to_string(), ]) - .replace_env(HashMap::from([("RUST_LOG".to_string(), "runtime=debug".to_string())])) + .replace_env( + HashMap::from([ + ("RUST_LOG".to_string(), "runtime=debug".to_string()), + ("KEY".to_string(), String::new()), + ]) + ) .set_publish_all_ports(true) .set_handle(handle) .set_start_policy(StartPolicy::Strict) diff --git a/substrate/client/tests/dht.rs b/substrate/client/tests/dht.rs index 2fd40b12..4ab177ad 100644 --- a/substrate/client/tests/dht.rs +++ b/substrate/client/tests/dht.rs @@ -14,7 +14,9 @@ async fn dht() { TestBodySpecification::with_image( Image::with_repository("serai-dev-serai").pull_policy(PullPolicy::Never), ) - .replace_env([("SERAI_NAME".to_string(), name.to_string())].into()) + .replace_env( + [("SERAI_NAME".to_string(), name.to_string()), ("KEY".to_string(), String::new())].into(), + ) .set_publish_all_ports(true) .set_handle(handle(name)) .set_start_policy(StartPolicy::Strict) diff --git a/substrate/client/tests/validator_sets.rs b/substrate/client/tests/validator_sets.rs index fc284f64..884a42db 100644 --- a/substrate/client/tests/validator_sets.rs +++ b/substrate/client/tests/validator_sets.rs @@ -100,7 +100,10 @@ async fn validator_set_rotation() { "local".to_string(), format!("--{name}"), ]) - .replace_env(HashMap::from([("RUST_LOG=runtime".to_string(), "debug".to_string())])) + .replace_env(HashMap::from([ + ("RUST_LOG".to_string(), "runtime=debug".to_string()), + ("KEY".to_string(), String::new()), + ])) .set_publish_all_ports(true) .set_handle(handle(name)) .set_start_policy(StartPolicy::Strict)