From b1f1950c9899f789421eb92f321de8ba13d8a8f3 Mon Sep 17 00:00:00 2001 From: Gabriel Augendre Date: Sat, 20 Nov 2021 15:13:26 +0100 Subject: [PATCH] Tweak coverage config --- pyproject.toml | 4 ++++ tasks.py | 6 +++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9b3e71a..2c58042 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -65,6 +65,10 @@ commands = poetry run inv test """ +[tool.coverage.run] +omit = ["tasks.py"] +branch = true + [build-system] requires = ["poetry-core>=1.0.0"] build-backend = "poetry.core.masonry.api" diff --git a/tasks.py b/tasks.py index 42a430d..25c8811 100644 --- a/tasks.py +++ b/tasks.py @@ -14,7 +14,11 @@ def test(ctx): @task def test_cov(ctx): with ctx.cd(BASE_DIR): - ctx.run(f"pytest --cov=.", pty=True, echo=True) + ctx.run( + f"pytest --cov=. --cov-report term-missing:skip-covered", + pty=True, + echo=True, + ) @task