Skip to content

Commit

Permalink
Fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
Half-Shot committed Oct 25, 2024
1 parent 57a0b1f commit 3ba42df
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/integration/forwardedMentionsTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,12 +87,12 @@ describe("Test: config.forwardMentionsToManagementRoom behaves correctly.", func
await mjolnir.protectedRoomsTracker.addProtectedRoom(protectedRoom);

await moderator.start();
let mentionCount = 0;
let mentions = new Set();
moderator.on(
"room.message",
noticeListener(this.mjolnir.managementRoomId, (event) => {
if (event.content.body.includes(`Bot mentioned`)) {
mentionCount++;
mentions.add(event.event_id);
}
}),
);
Expand All @@ -112,6 +112,6 @@ describe("Test: config.forwardMentionsToManagementRoom behaves correctly.", func
await delay(2000);
}

expect(mentionCount).toBe(1);
expect(mentions.size).toBe(1);
});
});

0 comments on commit 3ba42df

Please sign in to comment.