mirror of
https://github.com/chenhg5/cc-connect.git
synced 2026-07-07 15:12:21 +08:00
Add a new integration test suite that verifies real agent (Claude Code, Codex, Cursor, Gemini, OpenCode) interactions with a mock platform. Tests are gated by //go:build integration tag so they're excluded from normal CI. core/engine.go: - Add public ReceiveMessage(p, msg) method to allow test callers to inject messages into the engine tests/integration/agent_integration_test.go: - mockPlatform implementing core.Platform interface for test verification - agentPool for reusing agent instances across tests - Session tests: new session, /list, /switch, /stop, /new context clear, /history - Agent tests: claude code, codex, cursor, gemini (skip if quota), opencode (skip if no gitlab auth) - Command tests: /shell (skip if admin_from not set), /provider list - i18n: /lang zh language switch - Concurrency: session isolation, long text chunking, empty message handling docs/plans/2026-03-24-integration-tests.md: - Test plan listing all implemented and planned integration test cases Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>