From 062585fcddf17feeae7077172224705090aa2069 Mon Sep 17 00:00:00 2001 From: Deepyaman Datta Date: Tue, 27 May 2025 11:01:36 -0600 Subject: [PATCH] Replace `event_loop` removed in pytest-asyncio 1.0 Signed-off-by: Deepyaman Datta --- tests/pandas/test_decorators.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/pandas/test_decorators.py b/tests/pandas/test_decorators.py index 06944ef37..72d079b93 100644 --- a/tests/pandas/test_decorators.py +++ b/tests/pandas/test_decorators.py @@ -1,8 +1,8 @@ """Testing the Decorators that check a functions input or output.""" +import asyncio import pickle import typing -from asyncio import AbstractEventLoop import numpy as np import pandas as pd @@ -1095,7 +1095,7 @@ def star_args_kwargs( pd.testing.assert_frame_equal(expected, actual) -def test_coroutines(event_loop: AbstractEventLoop) -> None: +def test_coroutines() -> None: # pylint: disable=missing-class-docstring,too-few-public-methods,missing-function-docstring class Schema(DataFrameModel): col1: Series[int] @@ -1192,7 +1192,7 @@ async def check_coros() -> None: with pytest.raises(errors.SchemaError): await coro(bad_df) - event_loop.run_until_complete(check_coros()) + asyncio.get_event_loop().run_until_complete(check_coros()) class Schema(DataFrameModel):