Fix and reenable thread tests (#11343)
This commit is contained in:
parent
379916c737
commit
1f8c9aff1f
2 changed files with 5 additions and 8 deletions
|
|
@ -1,18 +1,17 @@
|
|||
discard """
|
||||
disabled: yes
|
||||
outputsub: "channel is empty"
|
||||
"""
|
||||
|
||||
# bug #1816
|
||||
|
||||
from random import random
|
||||
from random import rand
|
||||
from os import sleep
|
||||
|
||||
type PComm = ptr Channel[int]
|
||||
|
||||
proc doAction(outC: PComm) {.thread.} =
|
||||
for i in 0.. <5:
|
||||
sleep(random(100))
|
||||
for i in 0 ..< 5:
|
||||
sleep(rand(100))
|
||||
send(outC[], i)
|
||||
|
||||
var
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue