mirror of
https://github.com/nathom/streamrip.git
synced 2025-05-16 16:14:49 -04:00
Update
This commit is contained in:
parent
7cbd77edc5
commit
837e934476
31 changed files with 990 additions and 172 deletions
17
tests/fixtures/util.py
vendored
Normal file
17
tests/fixtures/util.py
vendored
Normal file
|
@ -0,0 +1,17 @@
|
|||
import asyncio
|
||||
|
||||
loop = asyncio.new_event_loop()
|
||||
|
||||
|
||||
def arun(coro):
|
||||
return loop.run_until_complete(coro)
|
||||
|
||||
|
||||
def afor(async_gen):
|
||||
async def _afor(async_gen):
|
||||
l = []
|
||||
async for item in async_gen:
|
||||
l.append(item)
|
||||
return l
|
||||
|
||||
return arun(_afor(async_gen))
|
Loading…
Add table
Add a link
Reference in a new issue