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(orca): 跨设备带图拒绝断言改走 toMatchObject,修联合类型访问报错

Zhang Yunjin931250aaf4af
diff --git a/apps/desktop/src/main/maker-ipc/__tests__/orcaRemoteWorkers.test.ts b/apps/desktop/src/main/maker-ipc/__tests__/orcaRemoteWorkers.test.ts
index 89392da315..3369044554 100644
--- a/apps/desktop/src/main/maker-ipc/__tests__/orcaRemoteWorkers.test.ts
+++ b/apps/desktop/src/main/maker-ipc/__tests__/orcaRemoteWorkers.test.ts
@@ -422,8 +422,10 @@ describe('wrapTeamDeps', () => {
dispatchMeta: { source: 'mcp', context: 'send_to_worker' },
} as never);
expect(result.ok).toBe(false);
- expect(result.dispatchOutcome).toMatchObject({ code: 'SEND_FAILED', accepted: false });
- expect(String(result.dispatchOutcome?.message)).toContain('image attachments');
+ expect(result.dispatchOutcome).toMatchObject({
+ code: 'SEND_FAILED', accepted: false,
+ message: expect.stringContaining('image attachments'),
+ });
expect(remoteInvoke.mock.calls.some(([, channel]) => channel === 'maker:input:enqueue')).toBe(false);
} finally { workers.stop(); }
});