From 33d0db364bbc4e95173a19230c3359cff4917664 Mon Sep 17 00:00:00 2001 From: Ankush Menat Date: Tue, 6 Feb 2024 15:36:48 +0530 Subject: [PATCH] feat: allow configuring coverage from envvar (#24788) --- frappe/commands/utils.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/frappe/commands/utils.py b/frappe/commands/utils.py index 6151a844e0..0bf5a0fd23 100644 --- a/frappe/commands/utils.py +++ b/frappe/commands/utils.py @@ -791,7 +791,12 @@ def run_tests( @click.option("--app", help="For App", default="frappe") @click.option("--build-number", help="Build number", default=1) @click.option("--total-builds", help="Total number of builds", default=1) -@click.option("--with-coverage", is_flag=True, help="Build coverage file") +@click.option( + "--with-coverage", + is_flag=True, + help="Build coverage file", + envvar="CAPTURE_COVERAGE", +) @click.option("--use-orchestrator", is_flag=True, help="Use orchestrator to run parallel tests") @click.option("--dry-run", is_flag=True, default=False, help="Dont actually run tests") @pass_context