Skip to content

Commit 0ddacb6

Browse files
Fix more 4.2.x/3.13.7 mixed mode incompatibilities
(cherry picked from commit b557f80)
1 parent 75b1d19 commit 0ddacb6

3 files changed

Lines changed: 53 additions & 39 deletions

File tree

deps/rabbit/test/cli_forget_cluster_node_SUITE.erl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ init_per_testcase(Testcase, Config) ->
7777
%% In a 4.2+ and 3.13.x mixed cluster, osiris 1.8.x (in 3.13.x) is
7878
%% incompatible with 1.10.x in terms of badrpc message handling.
7979
%% Skip all stream-related tests in mixed version mode.
80-
{skip, "stream tests are not mixed version compatible"};
80+
{skip, "forget_cluster_node streams-related tests are not mixed version compatible"};
8181
_ ->
8282
rabbit_ct_helpers:testcase_started(Config, Testcase),
8383
ClusterSize = ?config(rmq_nodes_count, Config),

deps/rabbit/test/logging_SUITE.erl

Lines changed: 49 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -154,44 +154,15 @@ init_per_testcase(Testcase, Config) ->
154154
%% The exchange output requires RabbitMQ to run. All testcases in this
155155
%% group will run in the context of that RabbitMQ node.
156156
exchange_output ->
157-
Config1 = rabbit_ct_helpers:set_config(
158-
Config,
159-
[{rmq_nodename_suffix, Testcase}]),
160-
Config2 = (
161-
case Testcase of
162-
use_exchange_logger_when_enabling_khepri_db ->
163-
rabbit_ct_helpers:set_config(
164-
Config1,
165-
[{rmq_nodes_count, 3},
166-
{metadata_store, mnesia}]);
167-
use_exchange_logger_when_enabling_all_feature_flags ->
168-
rabbit_ct_helpers:set_config(
169-
Config1,
170-
[{rmq_nodes_count, 3}]);
171-
_ ->
172-
rabbit_ct_helpers:set_config(
173-
Config1,
174-
[{rmq_nodes_count, 1}])
175-
end),
176-
LogCfg = {log, [
177-
{exchange, [{enabled, true}, {level, debug}]},
178-
{file, [{level, debug}]}
179-
]},
180-
Config3 = (
181-
case Testcase of
182-
use_exchange_logger_when_enabling_all_feature_flags ->
183-
rabbit_ct_helpers:merge_app_env(
184-
Config2, {rabbit, [LogCfg,
185-
{forced_feature_flags_on_init, []}
186-
]});
187-
_ ->
188-
rabbit_ct_helpers:merge_app_env(
189-
Config2, {rabbit, [LogCfg]})
190-
end),
191-
rabbit_ct_helpers:run_steps(
192-
Config3,
193-
rabbit_ct_broker_helpers:setup_steps() ++
194-
rabbit_ct_client_helpers:setup_steps());
157+
case Testcase =:= use_exchange_logger_when_enabling_all_feature_flags
158+
andalso rabbit_ct_helpers:is_mixed_versions() of
159+
true ->
160+
{skip,
161+
"use_exchange_logger_when_enabling_all_feature_flags has a 4.2.x/3.13.7 "
162+
"mixed mode incompatibility due to the lists of stable feature flags."};
163+
false ->
164+
init_per_testcase_exchange_output(Testcase, Config)
165+
end;
195166

196167
%% Other groups and testcases run the tested code directly without a
197168
%% RabbitMQ node running.
@@ -205,6 +176,46 @@ init_per_testcase(Testcase, Config) ->
205176
Config, {log_base_dir, LogBaseDir})
206177
end.
207178

179+
init_per_testcase_exchange_output(Testcase, Config) ->
180+
Config1 = rabbit_ct_helpers:set_config(
181+
Config,
182+
[{rmq_nodename_suffix, Testcase}]),
183+
Config2 = (
184+
case Testcase of
185+
use_exchange_logger_when_enabling_khepri_db ->
186+
rabbit_ct_helpers:set_config(
187+
Config1,
188+
[{rmq_nodes_count, 3},
189+
{metadata_store, mnesia}]);
190+
use_exchange_logger_when_enabling_all_feature_flags ->
191+
rabbit_ct_helpers:set_config(
192+
Config1,
193+
[{rmq_nodes_count, 3}]);
194+
_ ->
195+
rabbit_ct_helpers:set_config(
196+
Config1,
197+
[{rmq_nodes_count, 1}])
198+
end),
199+
LogCfg = {log, [
200+
{exchange, [{enabled, true}, {level, debug}]},
201+
{file, [{level, debug}]}
202+
]},
203+
Config3 = (
204+
case Testcase of
205+
use_exchange_logger_when_enabling_all_feature_flags ->
206+
rabbit_ct_helpers:merge_app_env(
207+
Config2, {rabbit, [LogCfg,
208+
{forced_feature_flags_on_init, []}
209+
]});
210+
_ ->
211+
rabbit_ct_helpers:merge_app_env(
212+
Config2, {rabbit, [LogCfg]})
213+
end),
214+
rabbit_ct_helpers:run_steps(
215+
Config3,
216+
rabbit_ct_broker_helpers:setup_steps() ++
217+
rabbit_ct_client_helpers:setup_steps()).
218+
208219
end_per_testcase(Testcase, Config) ->
209220
Config1 = case rabbit_ct_helpers:get_config(Config, rmq_nodes_count) of
210221
undefined ->

deps/rabbit/test/rabbit_stream_sac_coordinator_SUITE.erl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@
2828
-define(STATE, rabbit_stream_sac_coordinator).
2929
-define(MOD, rabbit_stream_sac_coordinator).
3030

31+
suite() ->
32+
[{timetrap, {seconds, 240}}].
33+
3134
all() ->
3235
[{group, tests}].
3336

0 commit comments

Comments
 (0)