Files
MealQuest/web/src/test/setup.ts
T
dev_agent 81c5085f9a
CI / ci (push) Successful in 1m40s
Feature 06: PWA shell and offline (#58)
Co-authored-by: dev_agent <dev_agent@cubecraftlabs.com>
2026-10-05 15:22:37 -04:00

11 lines
379 B
TypeScript

import '@testing-library/jest-dom/vitest'
import { cleanup } from '@testing-library/react'
import { afterEach } from 'vitest'
afterEach(() => {
cleanup()
// 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()
})