Skip to content

Commit

Permalink
clean code
Browse files Browse the repository at this point in the history
  • Loading branch information
tcm390 committed Feb 13, 2025
1 parent 4bad07f commit af71043
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions packages/plugin-discord/__tests__/message.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,10 @@ describe("Discord MessageManager", () => {
async (content) => {
mockMessage.content = content;

const result = await messageManager["_shouldRespond"](mockMessage, {});
const result = await messageManager["_shouldRespond"](
mockMessage,
{} as any
);
expect(result).toBe(true);
}
);
Expand Down Expand Up @@ -193,7 +196,7 @@ describe("Discord MessageManager", () => {

const mockAttachmentManager = {
processAttachments: processAttachmentsMock,
} as unknown as (typeof messageManager)["attachmentManager"]; // ✅ Correct typing
} as unknown as (typeof messageManager)["attachmentManager"];

// Override the private property with a mock
Object.defineProperty(messageManager, "attachmentManager", {
Expand Down

0 comments on commit af71043

Please sign in to comment.