From 7102fe1a182f3caed4f056600e9658d14031fe20 Mon Sep 17 00:00:00 2001 From: merwanehamadi Date: Wed, 5 Jul 2023 21:03:45 -0700 Subject: [PATCH] Rename '--reg' flag to '--maintain' (#58) --- .github/workflows/ci.yml | 1 + agbenchmark/start_benchmark.py | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6fb348e9..6a0f4503 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -106,3 +106,4 @@ jobs: run: | poetry install poetry run agbenchmark start --mock + poetry run agbenchmark start --mock --maintain diff --git a/agbenchmark/start_benchmark.py b/agbenchmark/start_benchmark.py index 959dee36..9c7b8e8d 100644 --- a/agbenchmark/start_benchmark.py +++ b/agbenchmark/start_benchmark.py @@ -25,9 +25,9 @@ def cli() -> None: @cli.command() @click.option("--category", default=None, help="Specific category to run") -@click.option("--reg", is_flag=True, help="Runs only regression tests") +@click.option("--maintain", is_flag=True, help="Runs only regression tests") @click.option("--mock", is_flag=True, help="Run with mock") -def start(category: str, reg: bool, mock: bool) -> int: +def start(category: str, maintain: bool, mock: bool) -> int: """Start the benchmark tests. If a category flag is provided, run the categories with that mark.""" # Check if configuration file exists and is not empty if not os.path.exists(CONFIG_PATH) or os.stat(CONFIG_PATH).st_size == 0: @@ -76,7 +76,7 @@ def start(category: str, reg: bool, mock: bool) -> int: if category: pytest_args.extend(["-m", category]) else: - if reg: + if maintain: print("Running all regression tests") tests_to_run = get_regression_tests() else: