|
11 | 11 | -include_lib("eunit/include/eunit.hrl"). |
12 | 12 | -include_lib("amqp_client/include/amqp_client.hrl"). |
13 | 13 | -include_lib("amqp10_common/include/amqp10_framing.hrl"). |
| 14 | +-include_lib("rabbitmq_ct_helpers/include/rabbit_assert.hrl"). |
14 | 15 |
|
15 | 16 | -compile([nowarn_export_all, |
16 | 17 | export_all]). |
@@ -3912,11 +3913,14 @@ leader_transfer_credit(QName, QType, Credit, Config) -> |
3912 | 3913 | %% Create queue with leader on node 1. |
3913 | 3914 | {_, _, LinkPair1} = Init = init(1, Config), |
3914 | 3915 | try |
3915 | | - {ok, #{type := QType}} = rabbitmq_amqp_client:declare_queue( |
3916 | | - LinkPair1, |
3917 | | - QName, |
3918 | | - #{arguments => #{<<"x-queue-type">> => {utf8, QType}, |
3919 | | - <<"x-queue-leader-locator">> => {utf8, <<"client-local">>}}}) |
| 3916 | + ?awaitMatch( |
| 3917 | + {ok, #{type := QType}}, |
| 3918 | + rabbitmq_amqp_client:declare_queue( |
| 3919 | + LinkPair1, |
| 3920 | + QName, |
| 3921 | + #{arguments => #{<<"x-queue-type">> => {utf8, QType}, |
| 3922 | + <<"x-queue-leader-locator">> => {utf8, <<"client-local">>}}}), |
| 3923 | + 60000) |
3920 | 3924 | after |
3921 | 3925 | ok = close(Init) |
3922 | 3926 | end, |
@@ -5512,12 +5516,15 @@ dead_letter_into_stream(Config) -> |
5512 | 5516 | <<"x-dead-letter-exchange">> => {utf8, <<>>}, |
5513 | 5517 | <<"x-dead-letter-routing-key">> => {utf8, QName1} |
5514 | 5518 | }}), |
5515 | | - {ok, #{type := <<"stream">>}} = rabbitmq_amqp_client:declare_queue( |
5516 | | - LinkPair1, |
5517 | | - QName1, |
5518 | | - #{arguments => #{<<"x-queue-type">> => {utf8, <<"stream">>}, |
5519 | | - <<"x-initial-cluster-size">> => {ulong, 1} |
5520 | | - }}), |
| 5519 | + ?awaitMatch( |
| 5520 | + {ok, #{type := <<"stream">>}}, |
| 5521 | + rabbitmq_amqp_client:declare_queue( |
| 5522 | + LinkPair1, |
| 5523 | + QName1, |
| 5524 | + #{arguments => #{<<"x-queue-type">> => {utf8, <<"stream">>}, |
| 5525 | + <<"x-initial-cluster-size">> => {ulong, 1} |
| 5526 | + }}), |
| 5527 | + 60000), |
5521 | 5528 | {ok, Receiver} = amqp10_client:attach_receiver_link( |
5522 | 5529 | Session1, <<"receiver">>, <<"/amq/queue/", QName1/binary>>, |
5523 | 5530 | settled, configuration, |
|
0 commit comments