Skip to content

Commit dc37d9e

Browse files
committed
Unit test for /readiness REST API endpoint
1 parent b993d76 commit dc37d9e

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
from app.endpoints.health import readiness_probe_get_method
2+
3+
4+
def test_readiness_probe(mocker):
5+
"""Test the readiness endpoint handler."""
6+
response = readiness_probe_get_method()
7+
assert response is not None
8+
assert response.ready is True
9+
assert response.reason == "service is ready"

0 commit comments

Comments
 (0)