forked from anomalyco/opencode
-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Goal
Extend the Pulse happy path integration tests to cover the adversarial verdict submission and pipeline completion phases, using TDD.
Why
The adversarial-pipeline agent was silently failing to submit verdicts (wrong tool invocation). We need tests that:
- Verify the adversarial agent has
taskctlin its allowed tools - Verify
processAdversarialVerdictscorrectly handles APPROVED → commitTask → stage:done - Verify the ops-pipeline commit flow completes and closes the task
- Catch any future regressions in the verdict→completion path
What to test
Test 1: adversarial-pipeline agent has taskctl permission
- Load the adversarial-pipeline agent config from agent.ts
- Assert that
taskctlis in its allowed permissions - This is a fast unit test, no I/O needed
Test 2: full pipeline completion after APPROVED verdict (extend pulse-happy-path.test.ts)
- Already have: open→developing→reviewing→adversarial-running
- Add: set APPROVED verdict on task → call processAdversarialVerdicts → verify stage:done, status:closed
- This already exists in pipeline.test.ts but should also be in the happy path flow
Test 3: ops-pipeline agent has correct permissions
- Assert ops-pipeline agent has git/bash permissions needed to commit
- Fast unit test
Acceptance Criteria
- Test verifies adversarial-pipeline has taskctl:allow permission
- Happy path test covers full flow through verdict → closed
- bun test passes, bun run typecheck passes
- Tests are in test/tasks/ alongside existing pipeline tests
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels