import React from 'react'; import '@testing-library/jest-dom/vitest'; import { cleanup } from '@testing-library/react'; import { afterEach, vi, beforeAll } from 'vitest'; beforeAll(() => { Object.defineProperty(navigator, 'clipboard', { value: { writeText: vi.fn().mockResolvedValue(undefined), readText: vi.fn().mockResolvedValue(''), }, writable: true, configurable: true, }); }); afterEach(() => { cleanup(); }); vi.mock('framer-motion', async () => { const actual = await vi.importActual('framer-motion'); return { ...actual, motion: { div: ({ children, ...props }: React.HTMLAttributes) =>
{children}
, button: ({ children, ...props }: React.ButtonHTMLAttributes) => , }, AnimatePresence: ({ children }: { children: React.ReactNode }) => <>{children}, }; });