[Python-checkins] cpython (3.5): asyncio.test_pep492: Add a test for asyncio.iscoroutinefunction
yury.selivanov
python-checkins at python.org
Wed Aug 5 20:48:29 CEST 2015
https://hg.python.org/cpython/rev/17129db11be3
changeset: 97285:17129db11be3
branch: 3.5
parent: 97283:9575858d45a4
user: Yury Selivanov <yselivanov at sprymix.com>
date: Wed Aug 05 14:47:33 2015 -0400
summary:
asyncio.test_pep492: Add a test for asyncio.iscoroutinefunction
files:
Lib/test/test_asyncio/test_pep492.py | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/Lib/test/test_asyncio/test_pep492.py b/Lib/test/test_asyncio/test_pep492.py
--- a/Lib/test/test_asyncio/test_pep492.py
+++ b/Lib/test/test_asyncio/test_pep492.py
@@ -107,6 +107,10 @@
self.assertTrue(asyncio.iscoroutine(FakeCoro()))
+ def test_iscoroutinefunction(self):
+ async def foo(): pass
+ self.assertTrue(asyncio.iscoroutinefunction(foo))
+
def test_function_returning_awaitable(self):
class Awaitable:
def __await__(self):
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list