Files
portfolio/__mocks__/@prisma/client.ts
denshooter e2c2585468 feat: update Projects component with framer-motion variants and improve animations
refactor: modify layout to use ClientOnly and BackgroundBlobsClient components

fix: correct import statement for ActivityFeed in the main page

fix: enhance sitemap fetching logic with error handling and mock support

refactor: convert BackgroundBlobs to default export for consistency

refactor: simplify ErrorBoundary component and improve error handling UI

chore: update framer-motion to version 12.24.10 in package.json and package-lock.json

test: add minimal Prisma Client mock for testing purposes

feat: create BackgroundBlobsClient for dynamic import of BackgroundBlobs

feat: implement ClientOnly component to handle client-side rendering

feat: add custom error handling components for better user experience
2026-01-08 01:39:17 +01:00

39 lines
1.1 KiB
TypeScript

// Minimal Prisma Client mock for tests
// Export a PrismaClient class with the used methods stubbed out.
export class PrismaClient {
project = {
findMany: jest.fn(async () => []),
findUnique: jest.fn(async (args: any) => null),
count: jest.fn(async () => 0),
create: jest.fn(async (data: any) => data),
update: jest.fn(async (data: any) => data),
delete: jest.fn(async (data: any) => data),
updateMany: jest.fn(async (data: any) => ({})),
};
contact = {
create: jest.fn(async (data: any) => data),
findMany: jest.fn(async () => []),
count: jest.fn(async () => 0),
update: jest.fn(async (data: any) => data),
delete: jest.fn(async (data: any) => data),
};
pageView = {
create: jest.fn(async (data: any) => data),
count: jest.fn(async () => 0),
deleteMany: jest.fn(async () => ({})),
};
userInteraction = {
create: jest.fn(async (data: any) => data),
groupBy: jest.fn(async () => []),
deleteMany: jest.fn(async () => ({})),
};
$connect = jest.fn(async () => {});
$disconnect = jest.fn(async () => {});
}
export default PrismaClient;