@@ -45,7 +45,21 @@ end_per_suite(Config) ->
45
45
rabbit_ct_broker_helpers :teardown_steps ()).
46
46
47
47
init_per_group (_ , Config ) ->
48
- Config .
48
+ AnyNodeIsMissingPlugin =
49
+ lists :any (
50
+ fun (N ) ->
51
+ try
52
+ rabbit_ct_broker_helpers :enable_plugin (Config , N , rabbitmq_local_exchange ),
53
+ false
54
+ catch
55
+ _ :_ -> true
56
+ end
57
+ end ,
58
+ rabbit_ct_broker_helpers :get_node_configs (Config , nodename )),
59
+ case AnyNodeIsMissingPlugin of
60
+ true -> {skip , " rabbitmq_local_exchange plugin not available" };
61
+ _ -> Config
62
+ end .
49
63
50
64
end_per_group (_ , Config ) ->
51
65
Config .
@@ -54,11 +68,6 @@ init_per_testcase(Testcase, Config) ->
54
68
TestCaseName = rabbit_ct_helpers :config_to_testcase_name (Config , Testcase ),
55
69
Config1 = rabbit_ct_helpers :set_config (Config , {test_resource_name ,
56
70
re :replace (TestCaseName , " /" , " -" , [global , {return , list }])}),
57
- Nodes = rabbit_ct_broker_helpers :get_node_configs (Config , nodename ),
58
- [case rabbit_ct_broker_helpers :enable_plugin (Config , N , rabbitmq_local_exchange ) of
59
- ok -> ok ;
60
- _ -> {skip }
61
- end || N <- Nodes ],
62
71
rabbit_ct_helpers :testcase_started (Config1 , Testcase ).
63
72
64
73
end_per_testcase (Testcase , Config ) ->
0 commit comments