docs: add coverage verification instruction to CLAUDE.md (#2050)

This commit is contained in:
Marcelo Trylesinski 2026-02-13 14:10:00 +01:00 • committed by GitHub
commit a287a40184
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -28,6 +28,9 @@ This document contains critical information about working with this codebase. Fo
- Bug fixes require regression tests
- IMPORTANT: The `tests/client/test_client.py` is the most well designed test file. Follow its patterns.
- IMPORTANT: Be minimal, and focus on E2E tests: Use the `mcp.client.Client` whenever possible.
- IMPORTANT: Before pushing, verify 100% branch coverage on changed files by running
`uv run --frozen pytest -x` (coverage is configured in `pyproject.toml` with `fail_under = 100`
and `branch = true`). If any branch is uncovered, add a test for it before pushing.
Test files mirror the source tree: `src/mcp/client/streamable_http.py` → `tests/client/test_streamable_http.py`
Add tests to the existing file for that module.