test: Fix test memory leakage by mocking RateLimiter

This commit is contained in:
Tom Moor
2022-08-12 15:14:58 +02:00
parent 990de127e3
commit 7deda03000
2 changed files with 18 additions and 0 deletions

View File

@@ -18,6 +18,8 @@ if (process.env.DATABASE_URL_TEST) {
require("@server/database/sequelize");
jest.mock("bull");
jest.mock("rate-limiter-flexible");
jest.mock("../RateLimiter");
// This is needed for the relative manual mock to be picked up
jest.mock("../queues");