summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Ansari <david.ansari@gmx.de>2023-03-17 15:54:33 +0000
committerDavid Ansari <david.ansari@gmx.de>2023-03-17 15:54:33 +0000
commitf5564da94ad87b82166d433c4ab2e6bc977c3e66 (patch)
treeafbf8f147b16b2f05f88c9d4b2a155209eb3752f
parent1a7dbdf1b0e85d6c9020e2e617249bb156ddc894 (diff)
downloadrabbitmq-server-git-f5564da94ad87b82166d433c4ab2e6bc977c3e66.tar.gz
Fix flaky test rabbit_mqtt_qos0_queue_overflow
The test always succeeds on `main` branch. The test also always succeeds on `mc` branch when running remotely: ``` bazel test //deps/rabbitmq_mqtt:reader_SUITE --test_env FOCUS="-group tests -case rabbit_mqtt_qos0_queue_overflow" --config=rbe-25 -t- --runs_per_test=50 ``` However, the test flakes when running on `mc` branch locally on the MAC: ``` make -C deps/rabbitmq_mqtt ct-reader t=tests:rabbit_mqtt_qos0_queue_overflow FULL=1 ``` with the following local changes: ``` ~/workspace/rabbitmq-server/deps/rabbitmq_mqtt mc *6 !1 > 3s direnv rb 2.7.2 diff --git a/deps/rabbitmq_mqtt/test/reader_SUITE.erl b/deps/rabbitmq_mqtt/test/reader_SUITE.erl index fb71eae375..21377a2e73 100644 --- a/deps/rabbitmq_mqtt/test/reader_SUITE.erl +++ b/deps/rabbitmq_mqtt/test/reader_SUITE.erl @@ -27,7 +27,7 @@ all() -> groups() -> [ - {tests, [], + {tests, [{repeat_until_any_fail, 30}], [ block_connack_timeout, handle_invalid_packets, @@ -43,7 +43,7 @@ groups() -> ]. suite() -> - [{timetrap, {seconds, 60}}]. + [{timetrap, {minutes, 60}}]. %% ------------------------------------------------------------------- %% Testsuite setup/teardown. ``` failes prior to this commit after the 2nd time and does not fail after this commit.
-rw-r--r--deps/rabbitmq_mqtt/test/reader_SUITE.erl4
1 files changed, 2 insertions, 2 deletions
diff --git a/deps/rabbitmq_mqtt/test/reader_SUITE.erl b/deps/rabbitmq_mqtt/test/reader_SUITE.erl
index fb71eae375..1f5ba05d98 100644
--- a/deps/rabbitmq_mqtt/test/reader_SUITE.erl
+++ b/deps/rabbitmq_mqtt/test/reader_SUITE.erl
@@ -247,7 +247,7 @@ rabbit_mqtt_qos0_queue_overflow(Config) ->
ok = rabbit_ct_broker_helpers:enable_feature_flag(Config, rabbit_mqtt_qos0_queue),
Topic = atom_to_binary(?FUNCTION_NAME),
- Msg = binary:copy(<<"x">>, 1000),
+ Msg = binary:copy(<<"x">>, 2000),
NumMsgs = 10_000,
%% Provoke TCP back-pressure from client to server by using very small buffers.
@@ -269,7 +269,7 @@ rabbit_mqtt_qos0_queue_overflow(Config) ->
end, lists:seq(1, NumMsgs)),
%% Give the server some time to process (either send or drop) the messages.
- timer:sleep(2000),
+ timer:sleep(2500),
%% Let's resume the receiving client to receive any remaining messages that did
%% not get dropped.