Skip to content

refactor: split provider implementations and add comprehensive CI#23

Merged
CrazyBoyM merged 2 commits into
mainfrom
refactor/split-providers-and-tests
Jan 20, 2026
Merged

refactor: split provider implementations and add comprehensive CI#23
CrazyBoyM merged 2 commits into
mainfrom
refactor/split-providers-and-tests

Conversation

@CrazyBoyM

Copy link
Copy Markdown
Contributor

Summary

  • Refactor monolithic provider.ts into modular architecture under src/infra/providers/
  • Add comprehensive GitHub Actions CI workflow with 4-stage pipeline
  • Add agent integration tests covering file operations, bash commands, and multi-turn conversations
  • Clean up outdated documentation and fix test bugs

Changes

Provider Architecture

  • Split providers into separate files (anthropic.ts, openai.ts, gemini.ts)
  • Create shared core utilities (errors, retry, usage, fork, logger)
  • Improve type safety with dedicated types.ts and utils.ts

CI/CD Pipeline

  • Stage 1: Lint, TypeCheck, Build
  • Stage 2: Unit tests
  • Stage 3: Provider E2E tests (matrix: anthropic, openai, gemini)
  • Stage 4: Agent integration tests

Testing

  • Add tests/integration/agent/ci-integration.test.ts with comprehensive agent tests
  • Add tests/integration/providers/multi-provider.test.ts
  • Fix management-manager test (archived directory path)
  • Register builtin tools for integration tests

Code Quality

  • Remove outdated docs (PROGRESS_REPORT, MIGRATION_V2.7, etc.)
  • Update .env.test.example with proper structure

Test plan

  • All unit tests pass (146 passing)
  • All E2E tests pass (anthropic, openai, gemini)
  • All agent integration tests pass (11 tests)
  • CI pipeline passes on GitHub Actions

🤖 Generated with Claude Code

CrazyBoyM and others added 2 commits January 21, 2026 04:24
Major refactoring of provider architecture and testing infrastructure:

Provider Architecture:
- Split monolithic provider.ts into modular architecture
- Create src/infra/providers/ with separate files per provider
- Add shared core utilities (errors, retry, usage, fork, logger)
- Improve type safety with dedicated types.ts and utils.ts

CI/CD Pipeline:
- Add GitHub Actions workflow with 4-stage pipeline
- Stage 1: Lint, TypeCheck, Build
- Stage 2: Unit tests
- Stage 3: Provider E2E tests (Anthropic, OpenAI, Gemini matrix)
- Stage 4: Agent integration tests

Agent Integration Tests:
- Add comprehensive ci-integration.test.ts
- Test file operations (create, read, edit, glob)
- Test bash commands (system info, ls, env vars)
- Test multi-turn context preservation
- Test resume/restore functionality
- Test error handling (missing files, failed commands)

Code Quality:
- Remove outdated documentation files (PROGRESS_REPORT, MIGRATION_V2.7, etc.)
- Update .env.test.example with proper structure
- Improve test assertions for provider flexibility
- Register builtin tools for integration tests

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
The test was checking for 'archived' directory but the SkillsManagementManager
uses '.archived' (with dot prefix). Fixed the test to check the correct path.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@CrazyBoyM
CrazyBoyM merged commit 6d63cd0 into main Jan 20, 2026
9 checks passed
@CrazyBoyM
CrazyBoyM deleted the refactor/split-providers-and-tests branch January 20, 2026 20:37
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.

1 participant