@@ -96,25 +96,36 @@ end_per_group(_, Config) ->
9696 rabbit_ct_broker_helpers :teardown_steps ()).
9797
9898init_per_testcase (Testcase , Config ) ->
99- Config1 = rabbit_ct_helpers :testcase_started (Config , Testcase ),
100- rabbit_ct_broker_helpers :rpc (Config , 0 , ? MODULE , delete_queues , []),
101- Name = rabbit_data_coercion :to_binary (Testcase ),
102- rabbit_ct_broker_helpers :rpc (Config , 0 , ? MODULE , delete_exchange , [Name ]),
103- Config2 = rabbit_ct_helpers :set_config (Config1 ,
104- [{queue_name , Name },
105- {alt_queue_name , <<Name /binary , " _alt" >>},
106- {exchange_name , Name }
107- ]),
108- rabbit_ct_helpers :run_steps (Config2 , rabbit_ct_client_helpers :setup_steps ()).
99+ case {Testcase , rabbit_ct_broker_helpers :configured_metadata_store (Config )} of
100+ {transient_queue_on_node_down , khepri } ->
101+ {skip , " Test irrelevant with Khepri" };
102+ _ ->
103+ Config1 = rabbit_ct_helpers :testcase_started (Config , Testcase ),
104+ rabbit_ct_broker_helpers :rpc (Config , 0 , ? MODULE , delete_queues , []),
105+ Name = rabbit_data_coercion :to_binary (Testcase ),
106+ rabbit_ct_broker_helpers :rpc (Config , 0 , ? MODULE , delete_exchange , [Name ]),
107+ Config2 = rabbit_ct_helpers :set_config (
108+ Config1 ,
109+ [{queue_name , Name },
110+ {alt_queue_name , <<Name /binary , " _alt" >>},
111+ {exchange_name , Name }
112+ ]),
113+ rabbit_ct_helpers :run_steps (Config2 , rabbit_ct_client_helpers :setup_steps ())
114+ end .
109115
110116end_per_testcase (Testcase , Config ) ->
111- rabbit_ct_broker_helpers :rpc (Config , 0 , ? MODULE , delete_queues , []),
112- rabbit_ct_broker_helpers :rpc (Config , 0 , ? MODULE , delete_exchange ,
113- [? config (exchange_name , Config )]),
114- Config1 = rabbit_ct_helpers :run_steps (
115- Config ,
116- rabbit_ct_client_helpers :teardown_steps ()),
117- rabbit_ct_helpers :testcase_finished (Config1 , Testcase ).
117+ case {Testcase , rabbit_ct_broker_helpers :configured_metadata_store (Config )} of
118+ {transient_queue_on_node_down , khepri } ->
119+ Config ;
120+ _ ->
121+ rabbit_ct_broker_helpers :rpc (Config , 0 , ? MODULE , delete_queues , []),
122+ rabbit_ct_broker_helpers :rpc (Config , 0 , ? MODULE , delete_exchange ,
123+ [? config (exchange_name , Config )]),
124+ Config1 = rabbit_ct_helpers :run_steps (
125+ Config ,
126+ rabbit_ct_client_helpers :teardown_steps ()),
127+ rabbit_ct_helpers :testcase_finished (Config1 , Testcase )
128+ end .
118129
119130% % -------------------------------------------------------------------
120131% % Testcases.
0 commit comments