From 3f6e0e269234c112ce3a599fb945199672cf0bb4 Mon Sep 17 00:00:00 2001 From: wishforge Date: Sun, 8 Nov 2026 22:24:11 -0800 Subject: [PATCH] =?UTF-8?q?=E2=9C=85=20Assert=20canceled=20runs=20fail=20t?= =?UTF-8?q?heir=20pending=20release=20with=20the=20cancellation=20reason?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/control-hardening.test.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/control-hardening.test.ts b/tests/control-hardening.test.ts index 5afe9e9..cd1e0de 100644 --- a/tests/control-hardening.test.ts +++ b/tests/control-hardening.test.ts @@ -399,9 +399,11 @@ describe('signed runner receipts and real rollback state machine', () => { const envelope = (await broker.poll(runner, environment.id))!; expect(envelope.payload.release.id).toBe(oldest.id); const status = async (id: string) => (await db.transaction('alpha', tx => tx.get('release', id)))!; + // Canceled runs fail their pending release outright (see run-lifecycle's invalidation case), + // so the stale release no longer waits on the queue with a "request a new release" reason. expect(await status(canceled.release.id)).toMatchObject({ status: 'failed', - failureReason: expect.stringContaining('request a new release'), + failureReason: 'The run was canceled', }); // Continuing the paused run may make its release current again. expect((await status(paused.release.id)).status).toBe('ready');