Skip to content

armgit / cindy

Public Imported from GitHub
0

Consider it done. The open-source AI agent that works out of the box · 想到,就能做到。开源、开箱即用的 AI Agent。

test(helper): preserve remote error code literal types

zqchris2d3a8134d172
diff --git a/apps/desktop/src/main/mcp-integrations/__tests__/sessionStatusRemote.test.ts b/apps/desktop/src/main/mcp-integrations/__tests__/sessionStatusRemote.test.ts
index 4665232b05..2702b23331 100644
--- a/apps/desktop/src/main/mcp-integrations/__tests__/sessionStatusRemote.test.ts
+++ b/apps/desktop/src/main/mcp-integrations/__tests__/sessionStatusRemote.test.ts
@@ -39,7 +39,7 @@ describe('remote session archive status', () => {
['IPC_ERROR', '[NOT_FOUND] Session does not exist', 'REMOTE_RESULT_UNKNOWN'],
['IPC_ERROR', '[INTERNAL] failure after write', 'REMOTE_RESULT_UNKNOWN'],
['INVOKE_TIMEOUT', '', 'REMOTE_RESULT_UNKNOWN'],
- ])('classifies %s / %s without retry or local fallback', async (code, message, expected) => {
+ ] as const)('classifies %s / %s without retry or local fallback', async (code, message, expected) => {
const s = setup({ ok: false, error: { code, message } });
expect(await s.setStatus(request)).toMatchObject({ ok: false, errorCode: expected, changed: [], failedSessionId: 's1', remainingSessionIds: ['s2', 's3'] });
expect(s.invoke).toHaveBeenCalledOnce();