Files
MealQuest/web/src/test/setup.ts
T

11 lines
379 B
TypeScript
Raw Normal View History

import '@testing-library/jest-dom/vitest'
import { cleanup } from '@testing-library/react'
import { afterEach } from 'vitest'
afterEach(() => {
cleanup()
2026-10-05 15:22:37 -04:00
// The verified-session marker and other device state must not leak between
// tests. Tests in the node environment (src/pwa.test.ts) have no storage.
if (typeof localStorage !== 'undefined') localStorage.clear()
})