(cherry picked from commit 2387022e8c)
This commit is contained in:
Michael Klishin 2021-06-21 14:43:29 +08:00
parent 6550cd1752
commit 0e6298d1ae
No known key found for this signature in database
GPG Key ID: E80EDCFA0CDB21EE
1 changed files with 4 additions and 0 deletions

View File

@ -77,11 +77,15 @@ shrink(Config) ->
publish_confirm(Ch, QName),
{ok, Out1} = rabbitmq_queues(Config, 0, ["shrink", Nodename2]),
?assertMatch(#{{"/", "shrink1"} := {2, ok}}, parse_result(Out1)),
%% removing a node can trigger a leader election, give this QQ some time
%% to do it
timer:sleep(1500),
Nodename1 = rabbit_ct_broker_helpers:get_node_config(Config, 1, nodename),
publish_confirm(Ch, QName),
{ok, Out2} = rabbitmq_queues(Config, 0, ["shrink", Nodename1]),
?assertMatch(#{{"/", "shrink1"} := {1, ok}}, parse_result(Out2)),
%% removing a node can trigger a leader election, give this QQ some time
%% to do it
timer:sleep(1500),
Nodename0 = rabbit_ct_broker_helpers:get_node_config(Config, 0, nodename),
publish_confirm(Ch, QName),