aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/test/lux/math.lux
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--stdlib/source/test/lux/math.lux14
1 files changed, 7 insertions, 7 deletions
diff --git a/stdlib/source/test/lux/math.lux b/stdlib/source/test/lux/math.lux
index db7bf302d..b83d89d4e 100644
--- a/stdlib/source/test/lux/math.lux
+++ b/stdlib/source/test/lux/math.lux
@@ -35,7 +35,7 @@
Test
(<| (_.covering /._)
($_ _.and
- (do {! random.monad}
+ (do [! random.monad]
[.let [~= (f.approximately? ..margin_of_error)]
angle (|> random.safe_frac (\ ! each (f.* /.tau)))]
($_ _.and
@@ -60,7 +60,7 @@
(_.cover [/.pi]
(~= (f./ +2.0 /.tau) /.pi))
))
- (do {! random.monad}
+ (do [! random.monad]
[sample (|> random.safe_frac (\ ! each (f.* +1000.0)))]
($_ _.and
(_.cover [/.ceil]
@@ -89,7 +89,7 @@
(/.pow +3.0)
(f.approximately? ..margin_of_error sample)))
))
- (do {! random.monad}
+ (do [! random.monad]
[.let [~= (f.approximately? ..margin_of_error)]
sample (\ ! each (f.* +10.0) random.safe_frac)
power (\ ! each (|>> (n.% 10) ++ n.frac) random.nat)]
@@ -105,7 +105,7 @@
(/.log_by sample)
(~= power))))
))
- (do {! random.monad}
+ (do [! random.monad]
[.let [~= (f.approximately? ..margin_of_error)]
angle (\ ! each (f.* /.tau) random.safe_frac)
sample (\ ! each f.abs random.safe_frac)
@@ -136,14 +136,14 @@
(inverse! /.asinh /.acsch sample)
(inverse! /.atanh /.acoth big)
)))
- (do {! random.monad}
+ (do [! random.monad]
[x (\ ! each (|>> (f.* +10.0) f.abs) random.safe_frac)
y (\ ! each (|>> (f.* +10.0) f.abs) random.safe_frac)]
(_.cover [/.hypotenuse]
(let [h (/.hypotenuse x y)]
(and (f.>= x h)
(f.>= y h)))))
- (do {! random.monad}
+ (do [! random.monad]
[.let [~= (f.approximately? ..margin_of_error)
tau/4 (f./ +4.0 /.tau)]
x (\ ! each (f.* tau/4) random.safe_frac)
@@ -159,7 +159,7 @@
(~= tau/4 (/.atan/2 +0.0 (f.abs y)))
(~= (f.opposite tau/4) (/.atan/2 +0.0 (f.opposite (f.abs y))))
(f.not_a_number? (/.atan/2 +0.0 +0.0))))))
- (do {! random.monad}
+ (do [! random.monad]
[of (\ ! each (|>> (n.% 10) ++) random.nat)]
(_.cover [/.factorial]
(and (n.= 1 (/.factorial 0))