feat(chat): 完善运行状态与权限交互
This commit is contained in:
@@ -390,6 +390,7 @@ describe("streamAgentChat", () => {
|
||||
skipAuthRedirect: true,
|
||||
}),
|
||||
);
|
||||
|
||||
});
|
||||
|
||||
it("calls permission reply endpoint", async () => {
|
||||
@@ -413,6 +414,19 @@ describe("streamAgentChat", () => {
|
||||
}),
|
||||
}),
|
||||
);
|
||||
|
||||
await replyAgentPermission("s1", "perm-2", "always");
|
||||
|
||||
expect(apiFetch).toHaveBeenLastCalledWith(
|
||||
expect.stringContaining("/api/v1/agent/sessions/s1/permission-responses"),
|
||||
expect.objectContaining({
|
||||
method: "POST",
|
||||
body: JSON.stringify({
|
||||
request_id: "perm-2",
|
||||
reply: "always",
|
||||
}),
|
||||
}),
|
||||
);
|
||||
});
|
||||
|
||||
it("submits refreshed credentials through the authenticated context", async () => {
|
||||
|
||||
Reference in New Issue
Block a user