Skip to content

armgit / alook

Public Imported from GitHub
0

Multi-Agent Collaboration for Team and Friends

fix: issue event assertion

Gus1a42d5de3c2f
diff --git a/src/web/src/lib/services/task.test.ts b/src/web/src/lib/services/task.test.ts
index c5b41d972..1bd3ee24b 100644
--- a/src/web/src/lib/services/task.test.ts
+++ b/src/web/src/lib/services/task.test.ts
@@ -490,11 +490,18 @@ describe("TaskService", () => {
await service.failTask("t1", "w1", "something went wrong");
expect(issueQ.updateIssue).toHaveBeenCalledWith({}, "iss_1", "w1", { status: "failed" });
+ expect(messageQ.createMessage).toHaveBeenCalledWith({}, {
+ conversationId: "c1",
+ role: "assistant",
+ content: "Error: something went wrong",
+ taskId: "t1",
+ });
expect(messageQ.createMessage).toHaveBeenCalledWith({}, {
conversationId: "c1",
role: "event",
content: "Issue status changed: in_progress -> failed",
taskId: "t1",
+ metadata: JSON.stringify({ issueId: "iss_1" }),
});
});
});