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.lux8
1 files changed, 4 insertions, 4 deletions
diff --git a/stdlib/source/test/lux/math.lux b/stdlib/source/test/lux/math.lux
index 79143b815..a659e8095 100644
--- a/stdlib/source/test/lux/math.lux
+++ b/stdlib/source/test/lux/math.lux
@@ -2,7 +2,7 @@
[lux #*
data/text/format
["_" test (#+ Test)]
- ["r" math/random]
+ ["r" math/random (#+ Random)]
[control
[monad (#+ Monad do)]]
[data
@@ -35,7 +35,7 @@
($_ _.and
(<| (_.context "Trigonometry")
(do r.monad
- [angle (|> r.frac (:: @ map (f/* /.tau)))]
+ [angle (|> r.safe-frac (:: @ map (f/* /.tau)))]
($_ _.and
(_.test "Sine and arc-sine are inverse functions."
(trigonometric-symmetry /.sin /.asin angle))
@@ -46,7 +46,7 @@
)))
(<| (_.context "Rounding")
(do r.monad
- [sample (|> r.frac (:: @ map (f/* +1000.0)))]
+ [sample (|> r.safe-frac (:: @ map (f/* +1000.0)))]
($_ _.and
(_.test "The ceiling will be an integer value, and will be >= the original."
(let [ceil'd (/.ceil sample)]
@@ -65,7 +65,7 @@
)))
(<| (_.context "Exponentials and logarithms")
(do r.monad
- [sample (|> r.frac (:: @ map (f/* +10.0)))]
+ [sample (|> r.safe-frac (:: @ map (f/* +10.0)))]
(_.test "Logarithm is the inverse of exponential."
(|> sample /.exp /.log (within? +1.0e-15 sample)))))
(<| (_.context "Greatest-Common-Divisor and Least-Common-Multiple")