mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-09 20:54:30 +00:00
fix(mentions): check mentionPatterns even when explicit mention is available
This commit is contained in:
committed by
Ayaan Zaidi
parent
fcc53bcf1b
commit
22b59d24ce
@@ -392,7 +392,7 @@ describe("monitorSlackProvider tool results", () => {
|
||||
expect(replyMock.mock.calls[0][0].WasMentioned).toBe(true);
|
||||
});
|
||||
|
||||
it("skips channel messages when another user is explicitly mentioned", async () => {
|
||||
it("accepts channel messages when mentionPatterns match even if another user is mentioned", async () => {
|
||||
slackTestState.config = {
|
||||
messages: {
|
||||
responsePrefix: "PFX",
|
||||
@@ -433,8 +433,8 @@ describe("monitorSlackProvider tool results", () => {
|
||||
controller.abort();
|
||||
await run;
|
||||
|
||||
expect(replyMock).not.toHaveBeenCalled();
|
||||
expect(sendMock).not.toHaveBeenCalled();
|
||||
expect(replyMock).toHaveBeenCalledTimes(1);
|
||||
expect(replyMock.mock.calls[0][0].WasMentioned).toBe(true);
|
||||
});
|
||||
|
||||
it("treats replies to bot threads as implicit mentions", async () => {
|
||||
|
||||
Reference in New Issue
Block a user