aboutsummaryrefslogtreecommitdiff
path: root/stdlib/test/test/lux.lux
diff options
context:
space:
mode:
authorEduardo Julian2019-02-04 00:19:57 -0400
committerEduardo Julian2019-02-04 00:19:57 -0400
commit71a6928d3db3b05144c33516db307d5975a94dee (patch)
treefe087b91903c0dda41bfa84423d4958e1778f1b6 /stdlib/test/test/lux.lux
parentcf9e3fa6fef24cc0828ab882661fa96dc6f2570d (diff)
Changed the naming style for structures.
Diffstat (limited to '')
-rw-r--r--stdlib/test/test/lux.lux22
1 files changed, 11 insertions, 11 deletions
diff --git a/stdlib/test/test/lux.lux b/stdlib/test/test/lux.lux
index 0e41a961c..0470be339 100644
--- a/stdlib/test/test/lux.lux
+++ b/stdlib/test/test/lux.lux
@@ -8,7 +8,7 @@
["." i64]]]
["." function]
["." math
- ["r" random (#+ Random) ("r/." Functor<Random>)]]
+ ["r" random (#+ Random) ("r/." functor)]]
["_" test (#+ Test)]]
[/
["/." cli]
@@ -17,7 +17,7 @@
(def: identity
Test
- (do r.Monad<Random>
+ (do r.monad
[self (r.unicode 1)]
($_ _.and
(_.test "Every value is identical to itself."
@@ -32,7 +32,7 @@
(def: increment-and-decrement
Test
- (do r.Monad<Random>
+ (do r.monad
[value r.i64]
($_ _.and
(_.test "'inc' and 'dec' are different."
@@ -55,7 +55,7 @@
(def: (even-or-odd rand-gen even? odd?)
(All [a] (-> (Random (I64 a)) (Predicate (I64 a)) (Predicate (I64 a)) Test))
- (do r.Monad<Random>
+ (do r.monad
[value rand-gen]
($_ _.and
(_.test "Every number is either even or odd."
@@ -78,7 +78,7 @@
(def: (choice rand-gen = [< choose])
(All [a] (-> (Random a) (Equivalence a) [(Order a) (Choice a)] Test))
- (do r.Monad<Random>
+ (do r.monad
[left rand-gen
right rand-gen
#let [choice (choose left right)]]
@@ -101,7 +101,7 @@
(def: (conversion rand-gen forward backward =)
(All [a b] (-> (Random a) (-> a b) (-> b a) (Equivalence a) Test))
- (do r.Monad<Random>
+ (do r.monad
[value rand-gen]
(_.test "Can convert between types in a lossless way."
(|> value forward backward (= value)))))
@@ -109,12 +109,12 @@
(def: frac-rev
(r.Random Rev)
(|> r.rev
- (:: r.Functor<Random> map (|>> (i64.left-shift 11) (i64.logical-right-shift 11)))))
+ (:: r.functor map (|>> (i64.left-shift 11) (i64.logical-right-shift 11)))))
(def: prelude-macros
Test
($_ _.and
- (do r.Monad<Random>
+ (do r.monad
[factor (r/map (|>> (n/% 10) (n/max 1)) r.nat)
iterations (r/map (n/% 100) r.nat)
#let [expected (n/* factor iterations)]]
@@ -126,7 +126,7 @@
(recur (inc counter) (n/+ factor value))
value)))))
- (do r.Monad<Random>
+ (do r.monad
[first r.nat
second r.nat
third r.nat]
@@ -162,7 +162,7 @@
(def: template
Test
- (do r.Monad<Random>
+ (do r.monad
[cat0 r.nat
cat1 r.nat]
(_.test "Template application is a stand-in for the templated code."
@@ -171,7 +171,7 @@
(def: cross-platform-support
Test
- (do r.Monad<Random>
+ (do r.monad
[on-default r.nat
on-fake-host r.nat
on-valid-host r.nat]