Files
cleveragents-core/features/plan_prompt_command.feature
T
HAL9000 abd4e83baa fix(cli): add timing.started ISO timestamp to plan prompt JSON envelope
- Capture started_at timestamp using datetime.now(UTC) before service call
- Add timing.started field to JSON envelope with ISO 8601 format
- Update step definitions to verify timing.started is present and valid
- Remove @tdd_expected_fail tag from plan_prompt_command.feature scenario

Fixes #9353
2026-06-03 03:03:14 -04:00

47 lines
2.3 KiB
Gherkin

Feature: Plan prompt command
As a CleverAgents user
I want to provide guidance to an executing plan
So that the plan can continue with human-in-the-loop input
Scenario: Plan prompt command is discoverable in help
When I run plan command help
Then help output should include plan prompt command
@tdd_issue @tdd_issue_4255
Scenario: Plan prompt delivers guidance and returns spec envelope in json
Given a mocked lifecycle service prompt response
When I run plan prompt with plan id "01HXM8C2ZK4Q7C2B3F2R4VYV6J" and guidance "Use mocks for database tests" in format "json"
Then the prompt command should succeed
And lifecycle prompt should be called with plan id "01HXM8C2ZK4Q7C2B3F2R4VYV6J" and guidance "Use mocks for database tests"
And prompt output envelope should contain command "plan prompt"
And prompt output envelope should contain status "ok"
And prompt output data should include queued guidance
Scenario Outline: Plan prompt renders successfully across output formats
Given a mocked lifecycle service prompt response
When I run plan prompt with plan id "01HXM8C2ZK4Q7C2B3F2R4VYV6J" and guidance "Use mocks for database tests" in format "<format>"
Then the prompt command should succeed
And prompt output should include guidance text "Use mocks for database tests"
Examples:
| format |
| rich |
| color |
| table |
| plain |
| json |
| yaml |
Scenario: Plan prompt aborts when plan is not in active execute phase
Given lifecycle service rejects prompt for inactive plan phase
When I run plan prompt with plan id "01HXM8C2ZK4Q7C2B3F2R4VYV6J" and guidance "Use mocks for database tests" in format "json"
Then the prompt command should abort
And prompt output should mention inactive execute phase
Scenario: A2A facade routes _cleveragents plan prompt to lifecycle service
Given an A2A facade with a lifecycle prompt service
When I dispatch _cleveragents plan prompt for plan "01HXM8C2ZK4Q7C2B3F2R4VYV6J" and guidance "Use mocks for database tests"
Then facade prompt response should not be a stub
And facade prompt response should contain plan id "01HXM8C2ZK4Q7C2B3F2R4VYV6J"
And facade prompt response should contain guidance "Use mocks for database tests"