From 25b66ee096cd9542ad20881fdb18956b9e8bbf65 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jean-S=C3=A9bastien=20P=C3=A9dron?= Date: Thu, 9 Nov 2023 12:01:25 +0100 Subject: [PATCH] peer_discovery_classic_config_SUITE: Fix `successful_discovery_with_a_subset_of_nodes_coming_online` [Why] The testcase was broken as part of the work on Khepri (#7206): all nodes were started, making it an equivalent of the `successful_discovery` testcase. [How] We drop the first entry in the list of nodes given to `rabbit_ct_broker_helpers`. This way, it won't be started at all while still being listed in the classic config parameter. --- deps/rabbit/test/peer_discovery_classic_config_SUITE.erl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/deps/rabbit/test/peer_discovery_classic_config_SUITE.erl b/deps/rabbit/test/peer_discovery_classic_config_SUITE.erl index beead47ef069..4341387a25a3 100644 --- a/deps/rabbit/test/peer_discovery_classic_config_SUITE.erl +++ b/deps/rabbit/test/peer_discovery_classic_config_SUITE.erl @@ -109,8 +109,10 @@ init_per_testcase(successful_discovery_with_a_subset_of_nodes_coming_online = Te ], Config2 = rabbit_ct_helpers:set_config(Config1, [ {rmq_nodename_suffix, Testcase}, + %% We remove the first node in the list: it will be considered by peer + %% discovery (see `cluster_nodes' below), but it won't be started. %% note: this must not include the host part - {rmq_nodes_count, NodeNames}, + {rmq_nodes_count, tl(NodeNames)}, {rmq_nodes_clustered, false} ]), NodeNamesWithHostname = [rabbit_nodes:make({Name, "localhost"}) || Name <- NodeNames],