aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/gleam/iterator_test.gleam12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/gleam/iterator_test.gleam b/test/gleam/iterator_test.gleam
index 5d10cb2..66e8bd4 100644
--- a/test/gleam/iterator_test.gleam
+++ b/test/gleam/iterator_test.gleam
@@ -193,13 +193,13 @@ pub fn append_test() {
test([1, 2], [3, 4])
}
-// a |> list.map(from_list) |> from_list |> concat |> to_list == list.concat(a)
-pub fn concat_test() {
+// a |> list.map(from_list) |> from_list |> flatten |> to_list == list.concat(a)
+pub fn flatten_test() {
let test = fn(lists) {
lists
|> list.map(iterator.from_list)
|> iterator.from_list
- |> iterator.concat
+ |> iterator.flatten
|> iterator.to_list
|> should.equal(list.concat(lists))
}
@@ -209,12 +209,12 @@ pub fn concat_test() {
test([[1, 2], [3, 4]])
}
-// a |> list.map(from_list) |> flatten |> to_list == list.concat(a)
-pub fn flatten_test() {
+// a |> list.map(from_list) |> concat |> to_list == list.concat(a)
+pub fn concat_test() {
let test = fn(lists) {
lists
|> list.map(iterator.from_list)
- |> iterator.flatten
+ |> iterator.concat
|> iterator.to_list
|> should.equal(list.concat(lists))
}