diff --git a/server/src/auth/auth.service.spec.ts b/server/src/auth/auth.service.spec.ts index 720a77a9..b47b291f 100644 --- a/server/src/auth/auth.service.spec.ts +++ b/server/src/auth/auth.service.spec.ts @@ -4,6 +4,7 @@ import { JwtService } from "@nestjs/jwt"; import { getModelToken } from "@nestjs/mongoose"; import { Model } from "mongoose"; import { User, UserDocument } from "./schemas/user.schema"; +import * as bcrypt from "bcrypt"; // Mock modules jest.mock("bcrypt", () => ({ @@ -15,8 +16,6 @@ jest.mock("nanoid", () => ({ nanoid: () => "mockNanoId123", })); -const bcrypt = require("bcrypt"); - describe("AuthService", () => { let service: AuthService; let userModel: Model;