Add a fibers-parallel test
This commit is contained in:
parent
47ff45d963
commit
a73fd1ca50
1 changed files with 18 additions and 0 deletions
|
@ -93,4 +93,22 @@
|
||||||
1))
|
1))
|
||||||
#:unwind? #t)))
|
#:unwind? #t)))
|
||||||
|
|
||||||
|
(run-fibers-for-tests
|
||||||
|
(lambda ()
|
||||||
|
(let ((a 0))
|
||||||
|
(call-with-values
|
||||||
|
(lambda ()
|
||||||
|
(fibers-parallel
|
||||||
|
(begin
|
||||||
|
(sleep 1)
|
||||||
|
1)
|
||||||
|
(begin
|
||||||
|
(set! a 1)
|
||||||
|
2)))
|
||||||
|
(lambda (a b)
|
||||||
|
(assert-equal a 1)
|
||||||
|
(assert-equal b 2)))
|
||||||
|
|
||||||
|
(assert-equal a 1))))
|
||||||
|
|
||||||
(display "parallelism test finished successfully\n")
|
(display "parallelism test finished successfully\n")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue