Skip to content

Commit 28be004

Browse files
authored
chore (ui/svelte): update chat test to use unified test server (#5465)
1 parent b3e1ab5 commit 28be004

File tree

3 files changed

+1051
-1173
lines changed

3 files changed

+1051
-1173
lines changed

.changeset/hot-glasses-design.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@ai-sdk/provider-utils': patch
3+
---
4+
5+
chore (provider-utils): add error method to TestStreamController

packages/provider-utils/src/test/unified-test-server.ts

+4
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,10 @@ export class TestResponseController {
235235
await this.writer.write(chunk);
236236
}
237237

238+
async error(error: Error): Promise<void> {
239+
await this.writer.abort(error);
240+
}
241+
238242
async close(): Promise<void> {
239243
await this.writer.close();
240244
}

0 commit comments

Comments
 (0)