Skip to content

Commit

Permalink
locust/argument_parser.py: add --max-run-time arg
Browse files Browse the repository at this point in the history
  • Loading branch information
samuelebstein committed Dec 9, 2024
1 parent 2e3b0c5 commit aedd120
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions locust/argument_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -416,6 +416,12 @@ def setup_parser_arguments(parser):
help="Stop after the specified amount of time, e.g. (300s, 20m, 3h, 1h30m, etc.). Only used together with --headless or --autostart. Defaults to run forever.",
env_var="LOCUST_RUN_TIME",
)
parser.add_argument(
"--max-run-time",
metavar="<time string>",
help="Maximum allowed run time that caps or overrides the --run-time setting. Accepts the same formats as run-time, e.g. (300s, 20m, 3h, 1h30m, etc.).",
env_var="LOCUST_MAX_RUN_TIME",
)
parser.add_argument(
"-l",
"--list",
Expand Down

0 comments on commit aedd120

Please sign in to comment.