File tree Expand file tree Collapse file tree 2 files changed +21
-3
lines changed
Expand file tree Collapse file tree 2 files changed +21
-3
lines changed Original file line number Diff line number Diff line change @@ -52,9 +52,9 @@ htmlcov/
5252.nox /
5353.coverage
5454.coverage. *
55+ coverage. *
5556.cache
5657nosetests.xml
57- coverage.xml
5858* .cover
5959* .py,cover
6060.hypothesis /
Original file line number Diff line number Diff line change @@ -6,11 +6,29 @@ run-all: install-deps format-python check-python test-python check-commits build
66
77# Install Python package dependencies
88install-deps :
9- uv sync
9+ uv sync --all-extras --dev
1010
1111# Run the Python tests
1212test-python :
13- uv run pytest
13+ # - A short traceback (tb) mode to make it easier to view
14+ # - Use the `src/` package (importlib)
15+ # - Use code coverage on the `src/` package
16+ # - If tests fail, do not generate coverage report
17+ # - Create the coverage report in XML (for badge), terminal, and HTML
18+ # - Trigger failure if below 90% code coverage
19+ uv run pytest \
20+ - -tb=short \
21+ - -import-mode=importlib \
22+ - -cov=src \
23+ - -no-cov-on-fail \
24+ - -cov-report=term \
25+ - -cov-report=xml \
26+ - -cov-report=html \
27+ - -cov-fail-under=90
28+ # Make the badge from the coverage report
29+ uv run genbadge coverage \
30+ - i coverage.xml \
31+ - o htmlcov/ coverage.svg
1432
1533# Check Python code with the linter for any errors that need manual attention
1634check-python :
You can’t perform that action at this time.
0 commit comments