Commit 6d0c4c38 authored by Yury Selivanov's avatar Yury Selivanov

asyncio.test_pep492: Add a test for asyncio.iscoroutinefunction

parent 315b748c
...@@ -107,6 +107,10 @@ class CoroutineTests(BaseTest): ...@@ -107,6 +107,10 @@ class CoroutineTests(BaseTest):
self.assertTrue(asyncio.iscoroutine(FakeCoro())) self.assertTrue(asyncio.iscoroutine(FakeCoro()))
def test_iscoroutinefunction(self):
async def foo(): pass
self.assertTrue(asyncio.iscoroutinefunction(foo))
def test_function_returning_awaitable(self): def test_function_returning_awaitable(self):
class Awaitable: class Awaitable:
def __await__(self): def __await__(self):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment