FAQ | This is a LIVE service | Changelog

Skip to content
Snippets Groups Projects
Commit 5fe231d0 authored by E. Evstafiev's avatar E. Evstafiev :bulb:
Browse files

Merge branch '2-make-healthcheck-naming-consistent-with-django-boilerplate' into 'main'

Resolve "Make healthcheck naming consistent with django boilerplate"

Closes #2

See merge request !2
parents 89b6a7b5 0c1b6441
No related branches found
No related tags found
1 merge request!2Resolve "Make healthcheck naming consistent with django boilerplate"
Pipeline #521478 passed
......@@ -6,6 +6,6 @@ client = TestClient(app)
def test_healthy():
response = client.get("/status")
response = client.get("/healthy")
assert response.status_code == 200
assert response.json() == {"status": "healthy"}
assert response.text == "ok"
from fastapi import FastAPI
from fastapi import FastAPI, Response
app = FastAPI()
......@@ -8,6 +8,6 @@ def read_root():
return {"Hello": "World"}
@app.get("/status")
@app.get("/healthy", response_class=Response)
def read_status():
return {"status": "healthy"}
return Response(content="ok", status_code=200)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment