summary refs log tree commit diff
path: root/tests
diff options
context:
space:
mode:
authorLeah Neukirchen <leah@vuxu.org>2022-11-19 17:23:53 +0100
committerLeah Neukirchen <leah@vuxu.org>2022-11-19 17:23:53 +0100
commita06b95c052b4e70fe6fe61f7d90874fb6be00b56 (patch)
tree057a33cfbd434fcfb05c996da1c4171f8858f577 /tests
parentc39f30f07f47346dc6699c59f56c549a786283fe (diff)
downloadmew-a06b95c052b4e70fe6fe61f7d90874fb6be00b56.tar.gz
mew-a06b95c052b4e70fe6fe61f7d90874fb6be00b56.tar.xz
mew-a06b95c052b4e70fe6fe61f7d90874fb6be00b56.zip
add ok->, ok->>, err->, err->> to ->
Diffstat (limited to 'tests')
-rw-r--r--tests/test.mew8
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/test.mew b/tests/test.mew
index 948837a..52de20a 100644
--- a/tests/test.mew
+++ b/tests/test.mew
@@ -370,7 +370,13 @@
         (into '() (cross-product '(a b c))))
   (test '() (into '() (cross-product))))
 
-; ->
+(test-group "->"
+  (test 6 (-> 3 -> inc -> + 2))
+  (test 9 (-> #f -> or 7 -> + 2))
+  (test 9 (-> 6 ->> or 7 -> + 2))
+  (test 7 (-> 5 ok-> inc ok-> + 1))
+  (test (err 7) (-> (err 7) ok-> inc ok-> + 1))
+  (test 7 (-> (err 6) err-> + 1)))
 
 ; fun->