chore: Fix types in tests 25/N.

This commit is contained in:
cpojer
2026-02-17 14:31:02 +09:00
parent 600022cdcc
commit 6e5df1dc0f
16 changed files with 118 additions and 78 deletions

View File

@@ -864,10 +864,15 @@ describe("runMessageAction accountId defaults", () => {
});
expect(handleAction).toHaveBeenCalled();
const ctx = handleAction.mock.calls[0]?.[0] as {
accountId?: string | null;
params: Record<string, unknown>;
};
const ctx = (handleAction.mock.calls as unknown as Array<[unknown]>)[0]?.[0] as
| {
accountId?: string | null;
params: Record<string, unknown>;
}
| undefined;
if (!ctx) {
throw new Error("expected action context");
}
expect(ctx.accountId).toBe("ops");
expect(ctx.params.accountId).toBe("ops");
});