MCPcopy Create free account
hub / github.com/TanStack/ai / throwing

Function throwing

packages/ai-claude-code/tests/translate.test.ts:437–450  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

435
436 it('emits synthetic tool results then rethrows when the SDK stream throws mid-run', async () => {
437 async function* throwing(): AsyncIterable<AgentSdkMessage> {
438 yield init
439 yield {
440 type: 'assistant',
441 message: {
442 id: 'msg-1',
443 content: [
444 { type: 'tool_use', id: 'toolu_5', name: 'Bash', input: {} },
445 ],
446 },
447 parent_tool_use_id: null,
448 }
449 throw new Error('aborted')
450 }
451
452 const chunks: Array<StreamChunk> = []
453 await expect(async () => {

Callers 1

translate.test.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected