summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorAndrey Orst <andreyorst@gmail.com>2020-11-12 21:06:49 +0300
committerAndrey Orst <andreyorst@gmail.com>2020-11-12 21:06:49 +0300
commit8cb6c1a5741f3f71cae18df1eedcf327ff99e718 (patch)
tree5bbddc4dd496c9c9df112d5c5a8ce11638098e5d /tests
parenta1851986383148593ca85675d3dafd1e8517481a (diff)
feature(core): support strings in seq
Diffstat (limited to 'tests')
-rw-r--r--tests/core.fnl7
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/core.fnl b/tests/core.fnl
index b0c02aa..1df3921 100644
--- a/tests/core.fnl
+++ b/tests/core.fnl
@@ -200,7 +200,9 @@
(assert-eq (seq {}) nil)
(assert-eq (seq [1]) [1])
(assert-eq (seq [1 2 3]) [1 2 3])
- (assert-eq (seq {:a 1}) [["a" 1]]))
+ (assert-eq (seq {:a 1}) [["a" 1]])
+ (assert-eq (seq "abc") ["a" "b" "c"])
+ (assert-eq (seq "абв") ["а" "б" "в"]))
(testing "mapv"
(assert-not (pcall mapv))
@@ -224,7 +226,8 @@
["Happy Days co." "Coffee With You"]
["secretary" "chief officer"])
["Bob Smith works as secretary at Happy Days co."
- "Alice Watson works as chief officer at Coffee With You"]))
+ "Alice Watson works as chief officer at Coffee With You"])
+ (assert-eq (table.concat (mapv string.upper "vaiv")) "VAIV"))
(testing "reduce"
(fn* add