From 897651acbbaea7417548281f2e96db38cc47967e Mon Sep 17 00:00:00 2001 From: Maxence Boutet Date: Mon, 16 Nov 2020 18:41:27 -0500 Subject: [PATCH] Fix failing test --- locust/test/test_runners.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/locust/test/test_runners.py b/locust/test/test_runners.py index 691b147692..09fac4ad81 100644 --- a/locust/test/test_runners.py +++ b/locust/test/test_runners.py @@ -1458,6 +1458,12 @@ def test_spawn_message_with_older_timestamp_is_rejected(self): class MyUser(User): wait_time = constant(1) + def start(self, group: Group): + # We do this so that the spawning does not finish + # too quickly + gevent.sleep(0.1) + return super().start(group) + @task def my_task(self): pass