aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/test/lux/control/concurrency/promise.lux
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/source/test/lux/control/concurrency/promise.lux')
-rw-r--r--stdlib/source/test/lux/control/concurrency/promise.lux16
1 files changed, 8 insertions, 8 deletions
diff --git a/stdlib/source/test/lux/control/concurrency/promise.lux b/stdlib/source/test/lux/control/concurrency/promise.lux
index 04dd1c220..51908a257 100644
--- a/stdlib/source/test/lux/control/concurrency/promise.lux
+++ b/stdlib/source/test/lux/control/concurrency/promise.lux
@@ -108,10 +108,10 @@
(i.>= (.int to-wait)
(duration.to-millis (instant.span pre post)))))))
(wrap (do /.monad
- [?left (/.or (/.delay 100 leftE)
- (/.delay 200 dummy))
- ?right (/.or (/.delay 200 dummy)
- (/.delay 100 rightE))]
+ [?left (/.or (wrap leftE)
+ (/.delay to-wait dummy))
+ ?right (/.or (/.delay to-wait dummy)
+ (wrap rightE))]
(_.cover' [/.or]
(case [?left ?right]
[(#.Left leftA) (#.Right rightA)]
@@ -121,10 +121,10 @@
_
false))))
(wrap (do /.monad
- [leftA (/.either (/.delay 100 leftE)
- (/.delay 200 dummy))
- rightA (/.either (/.delay 200 dummy)
- (/.delay 100 rightE))]
+ [leftA (/.either (wrap leftE)
+ (/.delay to-wait dummy))
+ rightA (/.either (/.delay to-wait dummy)
+ (wrap rightE))]
(_.cover' [/.either]
(n.= (n.+ leftE rightE)
(n.+ leftA rightA)))))