hermes - ✅(Solved) Fix feat(testing): add TDD infrastructure, coverage reporting, and pre-commit hooks [1 pull requests, 1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
NousResearch/hermes-agent#12597Fetched 2026-04-20 12:18:02
View on GitHub
Comments
0
Participants
1
Timeline
2
Reactions
0
Author
Participants
Timeline (top)
closed ×1cross-referenced ×1

The project lacks structured testing infrastructure for TDD workflows. There's no coverage reporting, no Makefile for convenient test commands, no pre-commit hooks, and no documented testing guidelines.

Root Cause

The project lacks structured testing infrastructure for TDD workflows. There's no coverage reporting, no Makefile for convenient test commands, no pre-commit hooks, and no documented testing guidelines.

Fix Action

Fixed

PR fix notes

PR #12599: feat(testing): add TDD infrastructure, coverage reporting, and pre-commit hooks

Description (problem / solution / changelog)

Summary

Adds structured testing infrastructure to support TDD workflows for the hermes-agent project.

Closes #12597

Changes

New files

  • Makefile (219 lines) — 20+ test commands: make test, make coverage, make test-specific FILE=..., make test-class, make test-single, etc.
  • .coveragerc — Branch coverage config with HTML/XML reports, exclusion patterns for non-testable code
  • .pre-commit-config.yaml — ruff, isort, file checks, and custom test-file checker hook
  • TESTING.md (370 lines) — Comprehensive TDD guide: philosophy, structure, writing tests, coverage requirements
  • TDD_SUMMARY.md — Implementation summary with test results and next steps
  • scripts/check_test_files.py — Pre-commit hook that warns when source files lack corresponding tests
  • tests/test_example_best_practices.py (27 tests) — Reference test file demonstrating 10 testing patterns

Modified files

  • .github/workflows/tests.yml — Added coverage reporting, Codecov upload, coverage threshold check job
  • pyproject.toml — Added pytest-cov dependency, 6 new pytest markers (e2e, slow, security, gateway, tools, agent, cli), warning filters
  • CONTRIBUTING.md — Added TDD workflow, make commands, pre-commit hooks to the checklist

Testing

  • All 27 tests in test_example_best_practices.py pass
  • Pre-existing suite failures are unrelated (Python 3.9 venv vs 3.10+ syntax in source files)
  • No secrets or sensitive data in any changes

Changed files

  • .coveragerc (added, +110/-0)
  • .github/workflows/tests.yml (modified, +56/-2)
  • .pre-commit-config.yaml (added, +72/-0)
  • CONTRIBUTING.md (modified, +27/-4)
  • Makefile (added, +219/-0)
  • TDD_SUMMARY.md (added, +210/-0)
  • TESTING.md (added, +370/-0)
  • pyproject.toml (modified, +13/-2)
  • scripts/check_test_files.py (added, +111/-0)
  • tests/test_example_best_practices.py (added, +318/-0)
RAW_BUFFERClick to expand / collapse

Summary

The project lacks structured testing infrastructure for TDD workflows. There's no coverage reporting, no Makefile for convenient test commands, no pre-commit hooks, and no documented testing guidelines.

What's needed

  • Makefile with convenient test commands (test, coverage, specific-file, class, method)
  • Coverage configuration (.coveragerc) with branch coverage, HTML/XML reports, and exclusion patterns
  • Pre-commit hooks (.pre-commit-config.yaml) with ruff, isort, file checks, and a test-file checker
  • Testing docs (TESTING.md, TDD_SUMMARY.md) documenting TDD practices and workflow
  • Example test file (test_example_best_practices.py) as a reference for contributors
  • CI updates (tests.yml) with coverage reporting, Codecov upload, and coverage threshold checking
  • pytest config (pyproject.toml) with pytest-cov dependency, new markers, and warning filters
  • CONTRIBUTING.md updates with TDD workflow and make commands

Acceptance criteria

  • All new test files pass
  • CI workflow includes coverage reporting
  • Makefile commands work (test, coverage, test-specific, etc.)
  • Pre-commit config is valid
  • No secrets or sensitive data in changes

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

hermes - ✅(Solved) Fix feat(testing): add TDD infrastructure, coverage reporting, and pre-commit hooks [1 pull requests, 1 participants]