asyncio: sync with Tulip

- Sort imports
- Simplify/optimize iscoroutine(). Inline inspect.isgenerator(obj): replace it
  with isinstance(obj, types.GeneratorType)
- CoroWrapper: check at runtime if Python has the yield-from bug #21209.  If
  Python has the bug, check if CoroWrapper.send() was called by yield-from to
  decide if parameters must be unpacked or not.
- Fix "Task was destroyed but it is pending!" warning in
  test_task_source_traceback()
This commit is contained in:
Victor Stinner 2014-06-30 14:39:11 +02:00
parent a6ec5ee3c8
commit b75380f333
3 changed files with 52 additions and 10 deletions

View file

@ -1621,6 +1621,7 @@ class TaskTests(test_utils.TestCase):
(__file__,
lineno,
'test_task_source_traceback'))
self.loop.run_until_complete(task)
class GatherTestsBase: