2 Commits

Author SHA1 Message Date
CrazyBoyM
e5ef71fb15 test: add comprehensive unit tests
Unit tests (no API required):
- test_imports: All agent modules importable
- test_todo_manager_basic: TodoManager CRUD
- test_todo_manager_constraints: Max items, one in_progress
- test_reminder_constants: INITIAL_REMINDER, NAG_REMINDER
- test_nag_reminder_in_agent_loop: NAG injection in correct place
- test_env_config: MODEL_ID, ANTHROPIC_BASE_URL from env
- test_default_model: Default model fallback
- test_tool_schemas: v1 tool definitions valid

CI now runs unit-test and integration-test as separate jobs.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-25 00:42:09 +08:00
CrazyBoyM
8f4a130371 ci: add GitHub Actions test workflow with real agent tests
Tests:
- test_bash_echo: Run simple bash command
- test_file_creation: Create and verify file
- test_directory_listing: List directory contents
- test_file_search: Search with grep
- test_multi_step_task: Multi-step file manipulation

Each test runs a complete agent loop (API call -> tool execution -> continue).

Required secrets:
- TEST_API_KEY: API key for testing
- TEST_BASE_URL: API base URL
- TEST_MODEL: Model (default: claude-3-5-sonnet-20241022)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-24 23:58:04 +08:00