diff --git a/tests/test_health.py b/tests/test_health.py index 5c5a580..536827a 100644 --- a/tests/test_health.py +++ b/tests/test_health.py @@ -5,12 +5,15 @@ def test_healthz_returns_ok(): app = create_app() client = app.test_client() resp = client.get("/healthz") - assert resp.status_code == 200 - assert resp.json["status"] == "ok" + if resp.status_code != 200: + raise AssertionError(f"Expected status code 200, got {resp.status_code}") + if resp.json["status"] != "ok": + raise AssertionError(f"Expected status 'ok', got {resp.json['status']}") def test_version_advertised(): app = create_app() client = app.test_client() resp = client.get("/healthz") - assert "version" in resp.json + if "version" not in resp.json: + raise AssertionError("Expected 'version' in response JSON") \ No newline at end of file