test(acp-snapshot): wait for the durable goal pause before disposal

The goal scenario asserted a paused revision-2 goal, but the pause is
appended only after cancellation reaches idle — after turn/end. Under
parallel snapshot files the subprocess could dispose before the pause
record persisted, folding the log to an active revision-1 goal.

Add a waitForEventAfterTurnEnd input step (the turn-end/title waiters'
shape, parameterized by event type) and use it in the goal scenario to
hold the subprocess open until the goal-state record lands.
This commit is contained in:
Turtle
2026-07-31 16:18:58 +08:00
parent ecdcc218b6
commit 5fc420c5c0
3 changed files with 53 additions and 18 deletions

View File

@@ -2,13 +2,10 @@
"steps": [
{ "op": "initialize" },
{ "op": "newSession" },
{
"op": "promptAndWaitForAgentMessage",
"text": "Create a durable two-round goal for the ACP snapshot, inspect it, then report readiness.",
"waitForText": "GOAL ROUND ONE"
},
{ "op": "promptAndWaitForAgentMessage", "text": "Create a durable two-round goal for the ACP snapshot, inspect it, then report readiness.", "waitForText": "GOAL ROUND ONE" },
{ "op": "waitForTurnStart", "minimumTurn": 3 },
{ "op": "cancel", "waitForFile": { "path": ".dsh-snapshot-goal-cancel-ready" } },
{ "op": "waitForTurnEnd" }
{ "op": "waitForTurnEnd" },
{ "op": "waitForEventAfterTurnEnd", "type": "user/message" }
]
}