move await engine.dispose() to test client

This commit is contained in:
grillazz
2022-02-02 13:54:41 +01:00
parent bed2d99bed
commit 2a6f09b71b
3 changed files with 5 additions and 3 deletions

View File

@@ -32,3 +32,6 @@ async def client() -> AsyncClient:
) as client:
await start_db()
yield client
# for AsyncEngine created in function scope, close and
# clean-up pooled connections
await engine.dispose()