Skip to content

Open-source Grok Bot alternative with a virtual machine that bots can use

test: reject failed room turns after waiting

Afloat5b7e793058b3
diff --git a/server/room-pages-point.e2e.test.ts b/server/room-pages-point.e2e.test.ts
index 3a2eb56a3e..a68fa4d358 100644
--- a/server/room-pages-point.e2e.test.ts
+++ b/server/room-pages-point.e2e.test.ts
@@ -36,7 +36,11 @@ it("sends a pick on a room page to the bot that made it, and to no other member"
});
expect(created.status, JSON.stringify(created.body)).toBeLessThan(300);
const group = created.body.group;
- const settled = async () => expect((await cli("wait", "--thread", group.threadId, "--timeout", "30")).status).toBe("settled");
+ const settled = async () => {
+ const waited = await cli("wait", "--thread", group.threadId, "--timeout", "30");
+ expect(waited.status).toBe("settled");
+ expect(waited.state).not.toBe("failed");
+ };
const transcript = async () => (await api(`/api/threads/${group.threadId}/messages?limit=50`)).body.messages as any[];
plan([{ tool: "show_html", arguments: { html: "<main><button>Go</button></main>", title: "Launch" } }]);