Add 62 tests across all planned phases + fix integration flakiness
- Phase 3: 19 API route integration tests (health, agents, sessions, messages)
- Phase 3: 7 WebSocket integration tests (connect, send, replay, invalid, stop)
- Phase 4: 9 agent tests (_check_context_size, _iter_stream_guarded)
- Phase 4: 5 planning tests (_parse_plan_steps)
- Phase 5: 22 tool tests (filesystem 13, code_exec 5, terminal 4)
- Fix flaky integration tests by patching module-level singletons
  (_session_store, _registries, _workers) instead of getter functions,
  because FastAPI Depends() captures the original function at import time.
- Update docs/testing.md coverage table (150 total tests)

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent 4e9dcef commit 6596822c0fcf13a432ac250d5f617361ee1be438
@Eugene Sukhodolskiy Eugene Sukhodolskiy authored on 29 Apr
Showing 10 changed files
View
docs/testing.md
View
tests/integration/conftest.py 0 → 100644
View
tests/integration/test_api_routes.py 0 → 100644
View
tests/integration/test_websocket.py 0 → 100644
View
tests/unit/core/test_agent_context_size.py 0 → 100644
View
tests/unit/core/test_agent_stream_guard.py 0 → 100644
View
tests/unit/core/test_planning.py 0 → 100644
View
tests/unit/tools/test_code_exec.py 0 → 100644
View
tests/unit/tools/test_filesystem.py 0 → 100644
View
tests/unit/tools/test_terminal.py 0 → 100644