Files
openchamber/packages/ui/src/components/chat/message/parts/ToolPart.test.ts
T

14 lines
527 B
TypeScript
Raw Normal View History

2026-06-08 11:50:56 -04:00
import { describe, expect, test } from 'bun:test';
import { readTaskTagSessionIdFromOutput } from './taskSessionIdParser';
describe('readTaskTagSessionIdFromOutput', () => {
test('parses task tags without state attributes', () => {
expect(readTaskTagSessionIdFromOutput('<task id="ses_abc123">')).toBe('ses_abc123');
});
test('parses task tags with additional attributes', () => {
expect(readTaskTagSessionIdFromOutput('<task id="ses_def456" state="completed">')).toBe('ses_def456');
});
});