From 686cb30f9d326f27fc18fea37276c94b2f10ad04 Mon Sep 17 00:00:00 2001 From: Tianyi Cui <53024+tianyicui@users.noreply.github.com> Date: Mon, 27 Jul 2026 09:41:23 +0800 Subject: [PATCH] fix: restore master's test casts mangled by a stale-types eslint --fix The interrupted pre-commit hook ran eslint --fix while client lib/types were stale, which stripped two deliberate 'as' casts from master's tests; one fails typecheck under exactOptionalPropertyTypes without it. Restore both files to master's content. --- packages/client/ui-conversation/tests/input-machine.spec.ts | 2 +- packages/client/ui-subagent/tests/browser-plugin.spec.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/client/ui-conversation/tests/input-machine.spec.ts b/packages/client/ui-conversation/tests/input-machine.spec.ts index a470044481..206a66e4c6 100644 --- a/packages/client/ui-conversation/tests/input-machine.spec.ts +++ b/packages/client/ui-conversation/tests/input-machine.spec.ts @@ -36,7 +36,7 @@ function effectAt( ): Extract { const e = effects[index] expect(e?.type).toBe(type) - return e + return e as Extract } /** Drive plain → adjudicating and hand back the minted attempt. */ diff --git a/packages/client/ui-subagent/tests/browser-plugin.spec.ts b/packages/client/ui-subagent/tests/browser-plugin.spec.ts index 828ef38837..fc74470406 100644 --- a/packages/client/ui-subagent/tests/browser-plugin.spec.ts +++ b/packages/client/ui-subagent/tests/browser-plugin.spec.ts @@ -22,7 +22,7 @@ function summary(partial: Partial & { id: SessionId }): SessionS running: false, updatedAt: 0, ...partial, - } + } as SessionSummary } const sid = (id: string) => id as SessionId