mirror of
https://github.com/python/cpython.git
synced 2025-11-03 03:22:27 +00:00
bpo-31709: Drop support for asynchronous __aiter__. (#3903)
This commit is contained in:
parent
86566702f3
commit
faa135acbf
9 changed files with 47 additions and 300 deletions
|
|
@ -660,7 +660,7 @@ class TestOneTrickPonyABCs(ABCTestCase):
|
|||
|
||||
def test_AsyncIterable(self):
|
||||
class AI:
|
||||
async def __aiter__(self):
|
||||
def __aiter__(self):
|
||||
return self
|
||||
self.assertTrue(isinstance(AI(), AsyncIterable))
|
||||
self.assertTrue(issubclass(AI, AsyncIterable))
|
||||
|
|
@ -674,7 +674,7 @@ class TestOneTrickPonyABCs(ABCTestCase):
|
|||
|
||||
def test_AsyncIterator(self):
|
||||
class AI:
|
||||
async def __aiter__(self):
|
||||
def __aiter__(self):
|
||||
return self
|
||||
async def __anext__(self):
|
||||
raise StopAsyncIteration
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue