-
Notifications
You must be signed in to change notification settings - Fork 79
Open
Labels
Description
Parent Issue
Part of #879 — Support Multi-Agent Execution Modes Per Task
Task
Comprehensive test coverage for the multi-agent execution feature.
Test Cases
TaskExecutionMode Config Tests
- Enum serializes/deserializes to task YAML correctly
- Per-task override takes precedence over global default
- Missing field defaults to null (falls back to global)
- Global default persists across settings changes
AgentRole & Context Builder Tests
- Implementer context includes full task spec + write instructions
- Reviewer context includes diff + acceptance criteria + verdict format
- Validator context includes test/lint instructions
- Revision context includes review comments from previous cycle
-
ChatMessageContextcarries role and previous phase output correctly
MultiAgentPhaseManager Tests
- SINGLE mode: one phase, immediate completion
- IMPLEMENTER_REVIEWER: two phases (implement → review), APPROVE → complete
- IMPLEMENTER_REVIEWER: REQUEST_CHANGES → revision → re-review cycle
- IMPLEMENTER_REVIEWER: max revisions exhausted → task marked for manual review
- VERIFY_ONLY: skips implementation, runs validation only
- Phase failure propagates correctly to runner
DiffCaptureService Tests
- Baseline captured correctly (git rev-parse HEAD)
- Diff captured between baseline and working tree
- Changed files list matches actual modifications
- Large diff truncated with summary
- Non-git project fallback works
ReviewVerdictParser Tests
- Structured APPROVE verdict parsed correctly
- Structured REQUEST_CHANGES with comments parsed correctly
- Fallback heuristic detects "approve" keyword
- Fallback heuristic detects "changes needed" / "reject" keywords
- Malformed output defaults to REQUEST_CHANGES (conservative)
- Empty output handled gracefully
Role-Based CLI Dispatch Tests
- Different tools selected for implementer vs. reviewer
- Default: same tool for all roles
- Tool config correctly passed to each phase execution
Files to Create
src/test/java/com/devoxx/genie/service/spec/MultiAgentPhaseManagerTest.java(new)src/test/java/com/devoxx/genie/service/spec/DiffCaptureServiceTest.java(new)src/test/java/com/devoxx/genie/service/spec/ReviewVerdictParserTest.java(new)src/test/java/com/devoxx/genie/service/spec/AgentRoleContextTest.java(new)
Dependencies
- Requires: All other [FEATURE] Support Multi-Agent Execution Modes Per Task #879 sub-tasks
Acceptance Criteria
- All test cases above pass
- No flaky tests
- Existing tests unaffected
- SINGLE mode regression tests confirm zero behavior change
Reactions are currently unavailable