aboutsummaryrefslogtreecommitdiffstats
path: root/thallium-backend/tests/test_app.py
diff options
context:
space:
mode:
Diffstat (limited to 'thallium-backend/tests/test_app.py')
-rw-r--r--thallium-backend/tests/test_app.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/thallium-backend/tests/test_app.py b/thallium-backend/tests/test_app.py
index c7c4937..254bb18 100644
--- a/thallium-backend/tests/test_app.py
+++ b/thallium-backend/tests/test_app.py
@@ -1,9 +1,9 @@
-from fastapi.testclient import TestClient
+import pytest
+from httpx import AsyncClient
-from src.app import fastapi_app
-
-def test_heartbeat() -> None:
+async def test_heartbeat(http_client: AsyncClient) -> None:
"""Ensure the heartbeat works."""
- with TestClient(app=fastapi_app) as client:
- assert client.get("/heartbeat").json() == {"detail": "I am alive!"}
+ resp = await http_client.get("/heartbeat")
+ assert resp.json() == {"detail": "I am alive!"}