Initialize HemHub project foundation

This commit is contained in:
Urban Modig
2026-07-23 22:06:56 +02:00
commit 9957383e88
23 changed files with 2430 additions and 0 deletions

21
frontend/src/App.test.tsx Normal file
View File

@ -0,0 +1,21 @@
import { render, screen } from '@testing-library/react'
import { afterEach, expect, test, vi } from 'vitest'
import App from './App'
afterEach(() => {
vi.restoreAllMocks()
})
test('visar sidans rubrik', () => {
vi.spyOn(globalThis, 'fetch').mockResolvedValue(
new Response(JSON.stringify({ status: 'UP' }), {
status: 200,
headers: { 'Content-Type': 'application/json' },
}),
)
render(<App />)
expect(screen.getByRole('heading', { name: 'HemHub' })).toBeInTheDocument()
})