test(bluebubbles): trim webhook auth import cost

This commit is contained in:
Vincent Koc
2026-04-01 03:05:59 +09:00
parent e5537f8b64
commit cb661122e2
2 changed files with 7 additions and 8 deletions

View File

@@ -50,13 +50,12 @@ vi.mock("./attachments.js", () => ({
}),
}));
vi.mock("./reactions.js", async () => {
const actual = await vi.importActual<typeof import("./reactions.js")>("./reactions.js");
return {
...actual,
sendBlueBubblesReaction: vi.fn().mockResolvedValue(undefined),
};
});
vi.mock("./reactions.js", () => ({
normalizeBlueBubblesReactionInput: vi.fn((emoji: string, remove?: boolean) =>
remove ? `-${emoji}` : emoji,
),
sendBlueBubblesReaction: vi.fn().mockResolvedValue(undefined),
}));
vi.mock("./history.js", () => ({
fetchBlueBubblesHistory: vi.fn().mockResolvedValue({ entries: [], resolved: true }),

View File

@@ -4,7 +4,7 @@
"defaultDurationMs": 1000,
"files": {
"extensions/bluebubbles/src/monitor.webhook-auth.test.ts": {
"durationMs": 115900,
"durationMs": 93900,
"testCount": 19
},
"extensions/matrix/src/plugin-entry.runtime.test.ts": {