pytest-coverage
Run pytest tests with coverage, discover lines missing coverage, and increase coverage to 100%.
Best use case
pytest-coverage is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Run pytest tests with coverage, discover lines missing coverage, and increase coverage to 100%.
Teams using pytest-coverage should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/pytest-coverage/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How pytest-coverage Compares
| Feature / Agent | pytest-coverage | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Run pytest tests with coverage, discover lines missing coverage, and increase coverage to 100%.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
The goal is for the tests to cover all lines of code. Generate a coverage report with: pytest --cov --cov-report=annotate:cov_annotate If you are checking for coverage of a specific module, you can specify it like this: pytest --cov=your_module_name --cov-report=annotate:cov_annotate You can also specify specific tests to run, for example: pytest tests/test_your_module.py --cov=your_module_name --cov-report=annotate:cov_annotate Open the cov_annotate directory to view the annotated source code. There will be one file per source file. If a file has 100% source coverage, it means all lines are covered by tests, so you do not need to open the file. For each file that has less than 100% test coverage, find the matching file in cov_annotate and review the file. If a line starts with a ! (exclamation mark), it means that the line is not covered by tests. Add tests to cover the missing lines. Keep running the tests and improving coverage until all lines are covered.
Related Skills
coverage-check
Lightweight test coverage analysis using git and file system heuristics. Identifies source files with no corresponding test file. No coverage tools required — works on any project by pattern matching. The CHECK skill for testing, analogous to validate-docs for documentation.
coverage-analysis
Coverage analysis measures code exercised during fuzzing. Use when assessing harness effectiveness or identifying fuzzing blockers.
genderapi-io-automation
Automate Genderapi IO tasks via Rube MCP (Composio). Always search tools first for current schemas.
gender-api-automation
Automate Gender API tasks via Rube MCP (Composio). Always search tools first for current schemas.
fred-economic-data
Query FRED (Federal Reserve Economic Data) API for 800,000+ economic time series from 100+ sources. Access GDP, unemployment, inflation, interest rates, exchange rates, housing, and regional data. Use for macroeconomic analysis, financial research, policy studies, economic forecasting, and academic research requiring U.S. and international economic indicators.
fidel-api-automation
Automate Fidel API tasks via Rube MCP (Composio). Always search tools first for current schemas.
fastapi-templates
Create production-ready FastAPI projects with async patterns, dependency injection, and comprehensive error handling. Use when building new FastAPI applications or setting up backend API projects.
fastapi-router-py
Create FastAPI routers with CRUD operations, authentication dependencies, and proper response models. Use when building REST API endpoints, creating new routes, implementing CRUD operations, or add...
fastapi-pro
Build high-performance async APIs with FastAPI, SQLAlchemy 2.0, and Pydantic V2. Master microservices, WebSockets, and modern Python async patterns.
expo-api-routes
Guidelines for creating API routes in Expo Router with EAS Hosting
esm
Comprehensive toolkit for protein language models including ESM3 (generative multimodal protein design across sequence, structure, and function) and ESM C (efficient protein embeddings and representations). Use this skill when working with protein sequences, structures, or function prediction; designing novel proteins; generating protein embeddings; performing inverse folding; or conducting protein engineering tasks. Supports both local model usage and cloud-based Forge API for scalable inference.
eodhd-apis-automation
Automate Eodhd Apis tasks via Rube MCP (Composio). Always search tools first for current schemas.