From 3b6c970ca56c609f6cf75d849c69664fa1aee4b8 Mon Sep 17 00:00:00 2001 From: Lars Holmberg Date: Thu, 25 Aug 2022 16:18:41 +0200 Subject: [PATCH] Use more clear wording in stopping message. --- locust/main.py | 4 ++-- locust/test/test_log.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/locust/main.py b/locust/main.py index faba894282..6b1ea02cf2 100644 --- a/locust/main.py +++ b/locust/main.py @@ -304,7 +304,7 @@ def stop_and_optionally_quit(): else: logger.info("--autoquit not specified, leaving web ui running indefinitely") else: # --headless run - logger.info("--run-time limit reached. Stopping Locust") + logger.info("--run-time limit reached, shutting down") runner.quit() def spawn_run_time_quit_greenlet(): @@ -325,7 +325,7 @@ def start_automatic_run(): start_time = time.monotonic() while len(runner.clients.ready) < options.expect_workers: if options.expect_workers_max_wait and options.expect_workers_max_wait < time.monotonic() - start_time: - logger.error("Gave up waiting for workers to connect.") + logger.error("Gave up waiting for workers to connect") runner.quit() sys.exit(1) logging.info( diff --git a/locust/test/test_log.py b/locust/test/test_log.py index a4968e7326..a550feacd6 100644 --- a/locust/test/test_log.py +++ b/locust/test/test_log.py @@ -77,7 +77,7 @@ def my_task(self): output, ) self.assertIn( - f"{socket.gethostname()}/INFO/locust.main: --run-time limit reached. Stopping Locust", + f"{socket.gethostname()}/INFO/locust.main: --run-time limit reached, shutting down", output, ) self.assertIn( @@ -192,7 +192,7 @@ def my_task(self): log_content, ) self.assertIn( - f"{socket.gethostname()}/INFO/locust.main: --run-time limit reached. Stopping Locust", + f"{socket.gethostname()}/INFO/locust.main: --run-time limit reached, shutting down", log_content, ) self.assertIn(