From f79e20712af6a974688e69186c40d537e035dbf4 Mon Sep 17 00:00:00 2001 From: Bugen Zhao Date: Fri, 29 Dec 2023 13:56:38 +0800 Subject: [PATCH] fix test and clippy Signed-off-by: Bugen Zhao --- src/cmd_all/src/standalone.rs | 12 ++++++++++-- src/common/src/util/meta_addr.rs | 3 +-- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/src/cmd_all/src/standalone.rs b/src/cmd_all/src/standalone.rs index d472430e34d7d..389731b08d11a 100644 --- a/src/cmd_all/src/standalone.rs +++ b/src/cmd_all/src/standalone.rs @@ -261,7 +261,11 @@ mod test { listen_addr: "127.0.0.1:8000", advertise_addr: None, prometheus_listener_addr: "127.0.0.1:1234", - meta_address: "http://127.0.0.1:5690", + meta_address: List( + [ + http://127.0.0.1:5690/, + ], + ), connector_rpc_endpoint: None, connector_rpc_sink_payload_format: None, config_path: "src/config/test.toml", @@ -281,7 +285,11 @@ mod test { listen_addr: "127.0.0.1:4566", advertise_addr: None, port: None, - meta_addr: "http://127.0.0.1:5690", + meta_addr: List( + [ + http://127.0.0.1:5690/, + ], + ), prometheus_listener_addr: "127.0.0.1:1234", health_check_listener_addr: "127.0.0.1:6786", config_path: "src/config/test.toml", diff --git a/src/common/src/util/meta_addr.rs b/src/common/src/util/meta_addr.rs index 37eb2e62d2f56..9564cc4587828 100644 --- a/src/common/src/util/meta_addr.rs +++ b/src/common/src/util/meta_addr.rs @@ -17,7 +17,7 @@ use std::str::FromStr; use itertools::Itertools; -const META_ADDRESS_LOAD_BALANCE_MODE_PREFIX: &'static str = "load-balance+"; +const META_ADDRESS_LOAD_BALANCE_MODE_PREFIX: &str = "load-balance+"; /// The strategy for meta client to connect to meta node. /// @@ -115,7 +115,6 @@ mod tests { } Some(strategy) => { assert_eq!(strategy, parsed_result.unwrap()); - assert_eq!(addr, strategy.to_string()); } } }