- import pytest
- from app.app import create_app
- @pytest.fixture()
- def app():
- app = create_app("testing")
- return app
- def test_health(app):
- client = app.test_client()
- resp = client.get("/health")
- assert resp.status_code == 200
- assert resp.get_json() == {"status": "ok"}
|