We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 0e02741 + 4e3835c commit 67f5f03Copy full SHA for 67f5f03
stac_fastapi/elasticsearch/tests/conftest.py
@@ -65,6 +65,7 @@ class Config:
65
@pytest.fixture(scope="session")
66
def event_loop():
67
loop = asyncio.new_event_loop()
68
+ asyncio.set_event_loop(loop)
69
yield loop
70
loop.close()
71
stac_fastapi/elasticsearch/tests/resources/test_mgmt.py
@@ -0,0 +1,13 @@
1
+import pytest
2
+
3
4
+@pytest.mark.asyncio
5
+async def test_ping_no_param(app_client):
6
+ """
7
+ Test ping endpoint with a mocked client.
8
+ Args:
9
+ app_client (TestClient): mocked client fixture
10
11
+ res = await app_client.get("/_mgmt/ping")
12
+ assert res.status_code == 200
13
+ assert res.json() == {"message": "PONG"}
0 commit comments