16 lines
384 B
TypeScript
16 lines
384 B
TypeScript
|
import { PrismaClient } from "@prisma/client";
|
||
|
import { mockDeep, mockReset, DeepMockProxy } from "jest-mock-extended";
|
||
|
|
||
|
import prisma from "@calcom/prisma";
|
||
|
|
||
|
jest.mock("@calcom/prisma", () => ({
|
||
|
__esModule: true,
|
||
|
default: mockDeep<PrismaClient>(),
|
||
|
}));
|
||
|
|
||
|
beforeEach(() => {
|
||
|
mockReset(prismaMock);
|
||
|
});
|
||
|
|
||
|
export const prismaMock = prisma as unknown as DeepMockProxy<PrismaClient>;
|