mirror of
https://github.com/fastapi-users/fastapi-users.git
synced 2025-08-15 11:11:16 +08:00
Fix pytest-asyncio warning regarding event loop fixture
This commit is contained in:
@ -128,9 +128,9 @@ class UserManagerMock(BaseTestUserManager[models.UP]):
|
||||
|
||||
@pytest.fixture(scope="session")
|
||||
def event_loop():
|
||||
"""Force the pytest-asyncio loop to be the main one."""
|
||||
loop = asyncio.get_event_loop()
|
||||
yield loop
|
||||
loop.close()
|
||||
|
||||
|
||||
AsyncMethodMocker = Callable[..., MagicMock]
|
||||
|
Reference in New Issue
Block a user