From 8cce5100ae799a267d7972c02b78a3fe7ef0a1ea Mon Sep 17 00:00:00 2001 From: Ilia Belov Date: Fri, 4 Nov 2022 11:33:25 +1300 Subject: [PATCH] Using event_loop instead loop DeprecationWarning: 'loop' fixture is deprecated and scheduled for removal, please use 'event_loop' instead --- docs/testing.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/testing.rst b/docs/testing.rst index 961f78f523c..6d590738f2c 100644 --- a/docs/testing.rst +++ b/docs/testing.rst @@ -111,11 +111,11 @@ app test client:: body='value: {}'.format(request.app[value]).encode('utf-8')) @pytest.fixture - def cli(loop, aiohttp_client): + def cli(event_loop, aiohttp_client): app = web.Application() app.router.add_get('/', previous) app.router.add_post('/', previous) - return loop.run_until_complete(aiohttp_client(app)) + return event_loop.run_until_complete(aiohttp_client(app)) async def test_set_value(cli): resp = await cli.post('/', data={'value': 'foo'})