BusyBee3333 4e6467ffb0 Add CRESync CRM application with Setup page
- Build complete Next.js CRM for commercial real estate
- Add authentication with JWT sessions and role-based access
- Add GoHighLevel API integration for contacts, conversations, opportunities
- Add AI-powered Control Center with tool calling
- Add Setup page with onboarding checklist (/setup)
- Add sidebar navigation with Setup menu item
- Fix type errors in onboarding API, GHL services, and control center tools
- Add Prisma schema with SQLite for local development
- Add UI components with clay morphism design system

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-14 17:30:55 -05:00

47 lines
827 B
TypeScript

import { vi } from 'vitest';
// Mock Prisma client
vi.mock('@/lib/db', () => ({
prisma: {
controlCenterConversation: {
create: vi.fn(),
findUnique: vi.fn(),
findMany: vi.fn(),
update: vi.fn(),
delete: vi.fn(),
count: vi.fn()
},
controlCenterMessage: {
create: vi.fn(),
findMany: vi.fn()
},
user: {
findUnique: vi.fn()
}
}
}));
// Mock Next.js cookies
vi.mock('next/headers', () => ({
cookies: vi.fn(() => ({
get: vi.fn(),
set: vi.fn(),
delete: vi.fn()
}))
}));
// Mock GHL helpers
vi.mock('@/lib/ghl/helpers', () => ({
getGHLClientForUser: vi.fn()
}));
// Mock settings service
vi.mock('@/lib/settings/settings-service', () => ({
settingsService: {
get: vi.fn()
}
}));
// Global fetch mock
global.fetch = vi.fn();