File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -153,13 +153,13 @@ def pytest_configure(config):
153153def pytest_pyfunc_call (pyfuncitem ):
154154 testfunction = pyfuncitem .obj
155155 if iscoroutinefunction (testfunction ):
156- msg = "Coroutine functions are not natively supported and have been skipped.\n "
156+ msg = "async def functions are not natively supported and have been skipped.\n "
157157 msg += "You need to install a suitable plugin for your async framework, for example:\n "
158158 msg += " - pytest-asyncio\n "
159159 msg += " - pytest-trio\n "
160160 msg += " - pytest-tornasync"
161161 warnings .warn (PytestUnhandledCoroutineWarning (msg .format (pyfuncitem .nodeid )))
162- skip (msg = "coroutine function and no async plugin installed (see warnings)" )
162+ skip (msg = "async def function and no async plugin installed (see warnings)" )
163163 funcargs = pyfuncitem .funcargs
164164 testargs = {arg : funcargs [arg ] for arg in pyfuncitem ._fixtureinfo .argnames }
165165 testfunction (** testargs )
Original file line number Diff line number Diff line change @@ -1199,11 +1199,11 @@ async def test_2():
11991199 [
12001200 "test_async.py::test_1" ,
12011201 "test_async.py::test_2" ,
1202- "*Coroutine functions are not natively supported*" ,
1202+ "*async def functions are not natively supported*" ,
12031203 "*2 skipped, 2 warnings in*" ,
12041204 ]
12051205 )
12061206 # ensure our warning message appears only once
12071207 assert (
1208- result .stdout .str ().count ("Coroutine functions are not natively supported" ) == 1
1208+ result .stdout .str ().count ("async def functions are not natively supported" ) == 1
12091209 )
You can’t perform that action at this time.
0 commit comments