TP_JO2024/medaille/tests/test_getMedaille.py
2024-03-27 15:20:10 +01:00

13 lines
314 B
Python

from models import Medaille
def test_getMedaille(client):
response = client.get("/1")
medaille = Medaille(
id=1,
type="Or",
sport="Judo",
categorie="80kg",
pays="France"
)
assert medaille.model_dump() == response.json
assert response.status_code == 200