Skip to content

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

test: assert both parity tool rounds and narration

Steven Enamakel9489a7080691
diff --git a/app/test/e2e/specs/chat-live-history-parity.spec.ts b/app/test/e2e/specs/chat-live-history-parity.spec.ts
index 5e944237a7..c34b13b9f4 100644
--- a/app/test/e2e/specs/chat-live-history-parity.spec.ts
+++ b/app/test/e2e/specs/chat-live-history-parity.spec.ts
@@ -128,6 +128,13 @@ async function replyBlocks(): Promise<Block[]> {
}
async function expandToolGroups(): Promise<void> {
+ await browser.waitUntil(
+ async () => (await browser.$$('[data-slot="tool-group-root"]')).length === 2,
+ {
+ timeout: 5_000,
+ timeoutMsg: 'expected the settled reply to contain both tool activity groups',
+ }
+ );
await clickToolGroupTrigger(0, '1 tool call');
await clickToolGroupTrigger(1, '1 tool call');
await browser.execute(() => {
@@ -301,6 +308,8 @@ describe('Chat live/history parity', () => {
block => block.kind === 'text' && block.text.includes(CANARY_FINAL)
);
expect(finalBlock).toBeDefined();
+ expect(settled.some(block => block.text.includes(FORCED_RESPONSES[0].content))).toBe(true);
+ expect(settled.some(block => block.text.includes(FORCED_RESPONSES[1].content))).toBe(true);
expect(normalizeRenderedText(finalBlock?.text ?? '')).toEqual(
normalizeRenderedText(FINAL_ANSWER)
);