chore(lint): burn down remaining warnings to zero
This commit is contained in:
@@ -39,7 +39,10 @@ describe('SyntheticClient', () => {
|
||||
it('streams content + done', async () => {
|
||||
const client = new SyntheticClient({ model: 'fixed:stream-me' });
|
||||
const events: string[] = [];
|
||||
for await (const ev of client.chatStream!(makeRequest('x'))) {
|
||||
if (!client.chatStream) {
|
||||
throw new Error('Expected streaming support');
|
||||
}
|
||||
for await (const ev of client.chatStream(makeRequest('x'))) {
|
||||
events.push(ev.type);
|
||||
}
|
||||
expect(events).toEqual(['content', 'done']);
|
||||
@@ -49,7 +52,10 @@ describe('SyntheticClient', () => {
|
||||
const client = new SyntheticClient({ model: 'echo' });
|
||||
const types: string[] = [];
|
||||
const toolNames: string[] = [];
|
||||
for await (const ev of client.chatStream!(makeRequest('@tool file.read {"path":"README.md"}'))) {
|
||||
if (!client.chatStream) {
|
||||
throw new Error('Expected streaming support');
|
||||
}
|
||||
for await (const ev of client.chatStream(makeRequest('@tool file.read {"path":"README.md"}'))) {
|
||||
types.push(ev.type);
|
||||
if (ev.type === 'tool_use' && ev.toolCall) {
|
||||
toolNames.push(ev.toolCall.name);
|
||||
@@ -59,4 +65,3 @@ describe('SyntheticClient', () => {
|
||||
expect(toolNames).toEqual(['file.read']);
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user