Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

fix(test): move conversation component tests into __tests__ directories

Steven Enamakel4dfd75f53532
diff --git a/app/src/features/conversations/components/ProcessingTranscriptView.test.tsx b/app/src/features/conversations/components/ProcessingTranscriptView.test.tsx
index c81b9dc099..9fc13cba18 100644
--- a/app/src/features/conversations/components/ProcessingTranscriptView.test.tsx
+++ b/app/src/features/conversations/components/ProcessingTranscriptView.test.tsx
@@ -120,8 +120,10 @@ describe('ProcessingTranscriptView live thinking', () => {
/>
);
const settled = screen.getByTestId('processing-thinking');
+ // `useT` is mocked to echo keys: the timed "Thought for {n}" key is
+ // chosen, not the untimed "Thought" fallback.
expect(settled.querySelector('[data-swap-layer="resting"]')?.textContent).toBe(
- 'chat.reasoning.thoughtFor'.replace('{n}', '12s')
+ 'chat.reasoning.thoughtFor'
);
expect(settled.querySelector('[data-slot="reasoning-step-title"]')?.textContent).toBe(
'Planning'
diff --git a/app/src/features/conversations/components/__tests__/SubagentDrawer.test.tsx b/app/src/features/conversations/components/__tests__/SubagentDrawer.test.tsx
index 4d079b2353..0a9ce2dd01 100644
--- a/app/src/features/conversations/components/__tests__/SubagentDrawer.test.tsx
+++ b/app/src/features/conversations/components/__tests__/SubagentDrawer.test.tsx
@@ -60,6 +60,9 @@ describe('SubagentDrawer', () => {
expect(order(tool)).toBeLessThan(order(texts[1]));
expect(thinking.textContent).toContain('comparing the two sources');
+ // Rendered through the shared reasoning panel, inline (no disclosure).
+ expect(thinking.getAttribute('data-variant')).toBe('static');
+ expect(thinking.querySelector('button')).toBeNull();
expect(tool.textContent).toContain('Searched the web');
expect(tool.textContent).toContain('1.2s');
expect(texts[1].textContent).toContain('The answer is');
diff --git a/app/src/features/conversations/timeline/ConversationTimeline.test.tsx b/app/src/features/conversations/timeline/ConversationTimeline.test.tsx
index 0b1425740b..3827d6755c 100644
--- a/app/src/features/conversations/timeline/ConversationTimeline.test.tsx
+++ b/app/src/features/conversations/timeline/ConversationTimeline.test.tsx
@@ -103,6 +103,11 @@ describe('ConversationTimeline', () => {
// Truncation ellipsis is present and the thinking summary renders.
expect(primary.textContent).toContain('…');
expect(primary.textContent).toContain('deliberating');
+ // The thinking renders through the live reasoning panel, not a raw
+ // hard-coded "Thinking…" <details>.
+ const thinking = screen.getByTestId('stream-primary-thinking');
+ expect(thinking.getAttribute('aria-busy') ?? thinking.querySelector('[aria-busy]')).toBeTruthy();
+ expect(primary.querySelector('details')).toBeNull();
// Only the last 120 chars of the 200-char body render in the content bubble.
const contentBubble = primary.querySelector('.font-mono.text-sm');
expect(contentBubble?.textContent).toBe(`…${'x'.repeat(120)}`);