Started work on testing

This commit is contained in:
Yarne Coppens 2024-08-01 14:31:17 +02:00
parent 7c08a285a9
commit 7598acddf9
2 changed files with 10 additions and 0 deletions

0
__init__.py Normal file
View file

10
test_main.py Normal file
View file

@ -0,0 +1,10 @@
from fastapi.testclient import TestClient
from .main import app
client = TestClient(app)
def test_read_main():
response = client.get("/")
assert response.status_code == 200
assert response.json() == {"Hello": "World"}