mirror of
https://github.com/supabase/supabase.git
synced 2026-05-06 08:56:46 -04:00
1cd1ebfc7f
Sorted all imports in all packages, `cms`, `design-system` and `ui-library` apps by running `pnpm format` on them. All changes in this PR are done by the script.
26 lines
639 B
TypeScript
26 lines
639 B
TypeScript
/// <reference types="@testing-library/jest-dom" />
|
|
import '@testing-library/jest-dom/vitest'
|
|
|
|
import { cleanup } from '@testing-library/react'
|
|
import { afterEach, vi } from 'vitest'
|
|
|
|
Object.defineProperty(window, 'matchMedia', {
|
|
writable: true,
|
|
value: vi.fn().mockImplementation((query) => ({
|
|
matches: false,
|
|
media: query,
|
|
onchange: null,
|
|
addListener: vi.fn(), // deprecated
|
|
removeListener: vi.fn(), // deprecated
|
|
addEventListener: vi.fn(),
|
|
removeEventListener: vi.fn(),
|
|
dispatchEvent: vi.fn(),
|
|
})),
|
|
})
|
|
|
|
vi.mock('next/navigation', () => require('next-router-mock'))
|
|
|
|
afterEach(() => {
|
|
cleanup()
|
|
})
|