Coverage Reference
Coverage Reference
Section titled “Coverage Reference”Complete reference for code coverage analysis in the IDX API.
Latest Coverage Report
Section titled “Latest Coverage Report”Coverage Metrics
Section titled “Coverage Metrics”The coverage report tracks:
| Metric | Description |
|---|---|
| Line Coverage | Percentage of source lines executed |
| Branch Coverage | Percentage of conditional branches taken |
| Function Coverage | Percentage of functions called |
| Missing Lines | Lines not covered by any test |
Target Modules
Section titled “Target Modules”Coverage is measured for all source modules under src/idx_api/:
Core Modules
Section titled “Core Modules”main.py- Application entry pointconfig.py- Configuration managementdatabase.py- Database connectionsauth.py- Authentication/authorization
Routers
Section titled “Routers”routers/admin.py- Admin endpointsrouters/agents.py- Agent managementrouters/brokerages.py- Brokerage operationsrouters/search.py- Property searchrouters/embeddings_admin.py- Vector search admin- And more…
Models
Section titled “Models”models/agent.pymodels/brokerage.pymodels/api_key.py- And more…
Coverage Goals
Section titled “Coverage Goals”| Module Type | Target | Notes |
|---|---|---|
| Routers | 80%+ | Critical paths must be covered |
| Models | 90%+ | Data models are straightforward |
| Auth | 95%+ | Security-critical code |
| Utilities | 70%+ | Helper functions |
Configuration
Section titled “Configuration”Coverage exclusions are configured in pyproject.toml:
[tool.coverage.run]omit = [ "*/tests/*", "*/__pycache__/*",]Inline Exclusions
Section titled “Inline Exclusions”Use # pragma: no cover to exclude specific lines:
if __name__ == "__main__": # pragma: no cover run()