aboutsummaryrefslogtreecommitdiff
path: root/stdlib/test
diff options
context:
space:
mode:
authorEduardo Julian2019-02-03 01:38:44 -0400
committerEduardo Julian2019-02-03 01:38:44 -0400
commit2607c95980e87f5f270e1fe6eaf7a7b3311ca138 (patch)
tree1ed1db89a9e7fd24f7d300b56aa19e4f9c4c4f39 /stdlib/test
parentfb9202536a4c668f477da2d85af484800e2a3f0c (diff)
Improved syntax for domains/parallel-import-trees.
Diffstat (limited to 'stdlib/test')
-rw-r--r--stdlib/test/test/lux.lux10
-rw-r--r--stdlib/test/test/lux/cli.lux2
-rw-r--r--stdlib/test/test/lux/data/maybe.lux17
-rw-r--r--stdlib/test/test/lux/host.jvm.lux2
-rw-r--r--stdlib/test/test/lux/host/jvm.jvm.lux2
5 files changed, 18 insertions, 15 deletions
diff --git a/stdlib/test/test/lux.lux b/stdlib/test/test/lux.lux
index 4be4b753b..72b9f45ef 100644
--- a/stdlib/test/test/lux.lux
+++ b/stdlib/test/test/lux.lux
@@ -4,7 +4,6 @@
[monad (#+ do)]
[predicate (#+ Predicate)]]
[data
- ["." maybe]
[number
["." i64]]]
["." math
@@ -155,15 +154,6 @@
_
false))))
- (do r.Monad<Random>
- [default r.nat
- maybe r.nat]
- (_.test "Can have defaults for Maybe values."
- (and (is? default (maybe.default default
- #.None))
-
- (is? maybe (maybe.default default
- (#.Some maybe))))))
))
(template: (hypotenuse cat0 cat1)
diff --git a/stdlib/test/test/lux/cli.lux b/stdlib/test/test/lux/cli.lux
index 7c50a679b..0ee1071e8 100644
--- a/stdlib/test/test/lux/cli.lux
+++ b/stdlib/test/test/lux/cli.lux
@@ -14,7 +14,7 @@
[math
["r" random]]
["_" test (#+ Test)]]
- {[-1 ""]
+ {1
["." /]})
(def: #export test
diff --git a/stdlib/test/test/lux/data/maybe.lux b/stdlib/test/test/lux/data/maybe.lux
index 4f135b68a..d47559d62 100644
--- a/stdlib/test/test/lux/data/maybe.lux
+++ b/stdlib/test/test/lux/data/maybe.lux
@@ -43,6 +43,16 @@
a (wrap "yolo")
b (wrap "lol")]
(wrap (f a b)))))
+
+ (do r.Monad<Random>
+ [default r.nat
+ maybe r.nat]
+ (_.test "Can have defaults for Maybe values."
+ (and (is? default (maybe.default default
+ #.None))
+
+ (is? maybe (maybe.default default
+ (#.Some maybe))))))
)))
(context: "Monad transformer"
@@ -52,5 +62,8 @@
[a (lift (io/wrap +123))
b (wrap +456)]
(wrap (i/+ a b))))
- (case> (#.Some +579) #1
- _ #0)))))
+ (case> (#.Some +579)
+ #1
+
+ _
+ #0)))))
diff --git a/stdlib/test/test/lux/host.jvm.lux b/stdlib/test/test/lux/host.jvm.lux
index f1151f010..3e184c7b9 100644
--- a/stdlib/test/test/lux/host.jvm.lux
+++ b/stdlib/test/test/lux/host.jvm.lux
@@ -8,7 +8,7 @@
[math
["r" random]]
["_" test (#+ Test)]]
- {[-1 ""]
+ {1
["." / (#+ import: class: interface: object)]})
(import: (java/util/concurrent/Callable a))
diff --git a/stdlib/test/test/lux/host/jvm.jvm.lux b/stdlib/test/test/lux/host/jvm.jvm.lux
index bacfd480b..2f5142e80 100644
--- a/stdlib/test/test/lux/host/jvm.jvm.lux
+++ b/stdlib/test/test/lux/host/jvm.jvm.lux
@@ -20,7 +20,7 @@
[math
["r" random]]
["_" test (#+ Test)]]
- {[-1 ""]
+ {1
[/
["/." loader (#+ Library)]
["/." version]