Skip to content

test: add contract tests for all ProgressPorts (fixes #87) - #233

Open
H-2006 wants to merge 1 commit into
OpenAgentHQ:mainfrom
H-2006:test-progress-ports
Open

H-2006 wants to merge 1 commit into
OpenAgentHQ:mainfrom
H-2006:test-progress-ports

Conversation

@H-2006

@H-2006 H-2006 commented Sep 21, 2026

Copy link
Copy Markdown

Summary

This PR adds contract tests for all ProgressPort implementations using a FakeEmitter to ensure regression safety when adapters change. Fixes #87.

Changes

  • Added a FakeEmitter class to capture progress events without printing to the screen.
  • Added contract tests for RichProgress, TqdmProgress, and SilentProgress in tests/unit/test_progress_ports.py.

Testing

  • Verified by running the unit tests locally using pytest tests/unit/test_progress_ports.py (all 3 tests passed).

Checklist

  • Branch named per Git Workflow (feature/, fix/, docs/, refactor/, test/, chore/)
  • Not developed on main
  • Code follows AGENT.md coding standards (type hints, Pydantic v2, no generic Exception, no business logic in CLI)
  • domain/ and ports/ stay pure (no I/O, no framework imports)
  • Quality gates pass locally: ruff, mypy --strict, bandit, pytest
  • Docs updated if behavior changed
  • pyproject.toml and src/modeldock/__init__.py versions match (if release-related)

This branch has not been deployed

No deployments
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.

Progress: unit tests for all ProgressPorts

1 participant