From d11cc0fb26b34e78ed2714e79b5f51284c334e25 Mon Sep 17 00:00:00 2001 From: crusaderky Date: Thu, 12 Dec 2024 10:59:08 +0000 Subject: [PATCH] Coverage report --- docs/contributing.md | 6 ++++++ pixi.lock | 2 +- pyproject.toml | 2 ++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/docs/contributing.md b/docs/contributing.md index b1f8b90..d9fa6be 100644 --- a/docs/contributing.md +++ b/docs/contributing.md @@ -43,6 +43,12 @@ pixi shell -e dev pixi run tests ``` +- To display the coverage report: + +``` +pixi run open-coverage +``` + - To build the docs locally: ``` diff --git a/pixi.lock b/pixi.lock index dbbc4b3..baf78aa 100644 --- a/pixi.lock +++ b/pixi.lock @@ -2375,7 +2375,7 @@ packages: - pypi: . name: array-api-extra version: 0.3.3.dev0 - sha256: 9daeca88bc9603038270c85c3043fc8fd1bb68ad817b7ed21db41e88c65b2964 + sha256: df8435cc57c8fbfe077b35f002a09eaa8fe096847c945c78ccd62b0f9ececbe7 requires_dist: - furo>=2023.8.17 ; extra == 'docs' - myst-parser>=0.13 ; extra == 'docs' diff --git a/pyproject.toml b/pyproject.toml index 4985b98..2aafebd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -102,6 +102,8 @@ numpy = "*" tests = { cmd = "pytest -v" } tests-ci = { cmd = "pytest -v -ra --cov --cov-report=xml --cov-report=term --durations=20" } tests-vendor = { cmd = "pytest vendor_tests" } +coverage = { cmd = ["coverage", "html"], depends-on = ["tests-ci"] } +open-coverage = { cmd = ["open", "htmlcov/index.html"], depends-on = ["coverage"] } [tool.pixi.feature.docs.dependencies] sphinx = ">=7.0"