@@ -79,9 +79,14 @@ merge_app_env(Config) ->
7979 {ra , [{min_wal_roll_over_interval , 30000 }]}).
8080
8181end_per_testcase (Testcase , Config ) ->
82- [Server0 , Server1 , Server2 ] =
82+ [Server0 , Server1 , Server2 ] = Servers =
8383 rabbit_ct_broker_helpers :get_node_configs (Config , nodename ),
8484 reset_nodes ([Server1 , Server2 ], Server0 ),
85+ lists :foreach (
86+ fun (Node ) ->
87+ clustering_utils :assert_cluster_status (
88+ {[Node ], [Node ], [Node ]}, [Node ])
89+ end , Servers ),
8590 Config1 = rabbit_ct_helpers :run_steps (
8691 Config ,
8792 rabbit_ct_client_helpers :teardown_steps ()),
@@ -90,19 +95,13 @@ end_per_testcase(Testcase, Config) ->
9095reset_nodes ([], _Leader ) ->
9196 ok ;
9297reset_nodes ([Node | Nodes ], Leader ) ->
93- Members = erpc :call (Leader , rabbit_nodes , all , []),
9498 ok = rabbit_control_helper :command (stop_app , Node ),
9599 case rabbit_control_helper :command (forget_cluster_node , Leader , [atom_to_list (Node )]) of
96100 ok -> ok ;
97101 {error , _ , <<" Error:\n {:not_a_cluster_node, ~c \" The node selected is not in the cluster.\" }" >>} -> ok
98102 end ,
99103 ok = rabbit_control_helper :command (reset , Node ),
100104 ok = rabbit_control_helper :command (start_app , Node ),
101- clustering_utils :assert_cluster_status ({[Node ], [Node ], [Node ]}, [Node ]),
102- RemainingNodes = Members -- [Node ],
103- clustering_utils :assert_cluster_status (
104- {RemainingNodes , RemainingNodes , RemainingNodes },
105- [Leader ]),
106105 reset_nodes (Nodes , Leader ).
107106
108107
0 commit comments