feat(runtime): add user-controlled turn recovery

This commit is contained in:
Xubin Ren
2026-08-24 00:58:04 +08:00
parent ffa58aa5ef
commit 12029f8812
60 changed files with 4027 additions and 169 deletions
+38
View File
@@ -103,6 +103,24 @@ describe("ChatList", () => {
);
});
it("marks a conversation that needs recovery attention with a warning indicator", () => {
render(
<ChatList
sessions={[session({ chatId: "recovery", title: "Interrupted task" })]}
recoveryChatIds={["recovery"]}
activeKey="websocket:other"
onSelect={vi.fn()}
onRequestDelete={vi.fn()}
onTogglePin={vi.fn()}
onRequestRename={vi.fn()}
onToggleArchive={vi.fn()}
/>,
);
expect(screen.getByRole("img", { name: "This conversation needs your attention" }))
.toBeInTheDocument();
});
it("keeps handle columns intact inside grouped panes", () => {
render(
<ChatList
@@ -151,6 +169,26 @@ describe("ChatList", () => {
}
});
it("shows the running indicator while a recovery continuation is active", () => {
render(
<ChatList
sessions={[session({ chatId: "recovery", title: "Interrupted task" })]}
runningChatIds={["recovery"]}
recoveryChatIds={["recovery"]}
activeKey="websocket:other"
onSelect={vi.fn()}
onRequestDelete={vi.fn()}
onTogglePin={vi.fn()}
onRequestRename={vi.fn()}
onToggleArchive={vi.fn()}
/>,
);
expect(screen.getByRole("img", { name: "Agent running" })).toBeInTheDocument();
expect(screen.queryByRole("img", { name: "This conversation needs your attention" }))
.not.toBeInTheDocument();
});
it("keeps tab grouping out of drag protocols while exposing inactive panes as mention sources", () => {
render(
<ChatList