Skip to content

Commit bc14f2f

Browse files
committed
uasyncio.core: test_fair_schedule.py: More checks and iterations.
1 parent 5925aa6 commit bc14f2f

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

uasyncio.core/test_fair_schedule.py

+7-2
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,12 @@
44
import uasyncio.core as asyncio
55

66

7-
COROS = 5
8-
ITERS = 5
7+
COROS = 10
8+
ITERS = 20
99

1010

1111
result = []
12+
test_finished = False
1213

1314

1415
async def coro(n):
@@ -18,10 +19,12 @@ async def coro(n):
1819

1920

2021
async def done():
22+
global test_finished
2123
while True:
2224
if len(result) == COROS * ITERS:
2325
#print(result)
2426
assert result == list(range(COROS)) * ITERS
27+
test_finished = True
2528
return
2629
yield
2730

@@ -32,3 +35,5 @@ async def done():
3235
loop.create_task(coro(n))
3336

3437
loop.run_until_complete(done())
38+
39+
assert test_finished

0 commit comments

Comments
 (0)