Files
SigHej/backend/tests/test_health.py

13 lines
370 B
Python
Raw Permalink Normal View History

2026-05-12 18:21:25 +02:00
import pytest
from httpx import ASGITransport, AsyncClient
from app.main import app
@pytest.mark.asyncio
async def test_health() -> None:
async with AsyncClient(transport=ASGITransport(app=app), base_url="http://test") as client:
response = await client.get("/health")
assert response.status_code == 200
assert response.json() == {"status": "ok"}