Skip to content

test: add local coverage reporting - #48

Merged
michalmaj merged 1 commit into
mainfrom
test/add-coverage
Sep 26, 2026
Merged

michalmaj merged 1 commit into
mainfrom
test/add-coverage

Conversation

@michalmaj

Copy link
Copy Markdown
Owner

Summary

Add local statement and branch coverage reporting without introducing a percentage gate.

Why

Coverage can reveal source code that tests never execute, but a high percentage does not prove that assertions or requirements are correct. The guide should teach coverage as diagnostic evidence rather than a score to maximize.

Changes

  • add pytest-cov as a locked development dependency
  • configure branch measurement and missing-line reporting in pyproject.toml
  • add a focused coverage chapter and connect it to the main learning path
  • update configuration, glossary, common questions, and roadmap references

Type of change

Select the most relevant option.

  • Documentation
  • Project configuration
  • New feature
  • Tests
  • CI/CD
  • Refactoring
  • Bug fix

Checklist

  • The change is small and focused
  • The pull request title is clear
  • I updated documentation if needed
  • I added or updated tests if needed
  • I ran local checks if applicable

Notes

The project intentionally does not configure fail_under. The current report
is 100% statement and branch coverage because the example package is very small;
that result is not treated as a quality guarantee.

This is the bottom pull request in the coverage stack. The follow-up 8B pull
request adds coverage reporting to CI.

Local checks passed:

  • uv run pytest --cov=text_toolkit --cov-report=term-missing
  • uv run mypy
  • uv run ruff check .
  • uv run ruff format --check .
  • uv build --no-sources
  • git diff --check

@michalmaj
michalmaj merged commit eb8e47b into main Sep 26, 2026
1 check passed
@michalmaj
michalmaj deleted the test/add-coverage branch September 26, 2026 14:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant