mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Just try to set custom event loop policy manually
This commit is contained in:
parent
dc412543ed
commit
a9369c3520
1 changed files with 2 additions and 4 deletions
|
|
@ -40,7 +40,8 @@ def pytest_configure(config):
|
||||||
|
|
||||||
if sys.platform == "win32":
|
if sys.platform == "win32":
|
||||||
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
|
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
|
||||||
return asyncio.set_event_loop_policy(asyncio.DefaultEventLoopPolicy())
|
else:
|
||||||
|
asyncio.set_event_loop_policy(asyncio.DefaultEventLoopPolicy())
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture()
|
@pytest.fixture()
|
||||||
|
|
@ -53,7 +54,6 @@ def redis_server(request):
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture()
|
@pytest.fixture()
|
||||||
@pytest.mark.redis
|
|
||||||
async def redis_storage(redis_server):
|
async def redis_storage(redis_server):
|
||||||
try:
|
try:
|
||||||
parse_redis_url(redis_server)
|
parse_redis_url(redis_server)
|
||||||
|
|
@ -82,7 +82,6 @@ def mongo_server(request):
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture()
|
@pytest.fixture()
|
||||||
@pytest.mark.mongo
|
|
||||||
async def mongo_storage(mongo_server):
|
async def mongo_storage(mongo_server):
|
||||||
try:
|
try:
|
||||||
parse_mongo_url(mongo_server)
|
parse_mongo_url(mongo_server)
|
||||||
|
|
@ -113,7 +112,6 @@ async def memory_storage():
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture()
|
@pytest.fixture()
|
||||||
@pytest.mark.redis
|
|
||||||
async def redis_isolation(redis_storage):
|
async def redis_isolation(redis_storage):
|
||||||
isolation = redis_storage.create_isolation()
|
isolation = redis_storage.create_isolation()
|
||||||
return isolation
|
return isolation
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue