"""infra routers unit tests.""" from fastapi.testclient import TestClient def test_hello(test_client: TestClient) -> None: """Verify the /hello/ endpoint responds with 200 and OK status.""" response = test_client.get("/hello/") assert response.status_code == 200 assert response.json() == {"status": "ok"} def test_root(test_client: TestClient) -> None: """Verify the / endpoint responds with 200 and OK status.""" response = test_client.get("/") assert response.status_code == 200 assert response.json() == {"Hello": "World!"} def test_oops(test_client: TestClient) -> None: """Verify the /oops/ endpoint responds with 500 and error response.""" response = test_client.get("/oops/") assert response.status_code == 500 assert response.json() == { "code": "bad_request", "message": "Something went wrong", }