(x)
| 170 | |
| 171 | # 2. Python asyncio.Task to JS promise |
| 172 | async def coro_fn(x): |
| 173 | await asyncio.sleep(0.01) |
| 174 | return x |
| 175 | task = loop.create_task(coro_fn("from a Task")) |
| 176 | assert type(task) is asyncio.Task |
| 177 | assert type(task) is not asyncio.Future |