diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/gleam/string_test.gleam | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/gleam/string_test.gleam b/test/gleam/string_test.gleam index f4f9089..3f278f6 100644 --- a/test/gleam/string_test.gleam +++ b/test/gleam/string_test.gleam @@ -74,3 +74,17 @@ pub fn concat_test() { |> string.concat |> expect.equal(_, "Hello, world!") } + +pub fn join_test() { + [ + "Hello", "world!", + ] + |> string.join(_, with: ", ") + |> expect.equal(_, "Hello, world!") + + [ + "Hello", "world!", + ] + |> string.join(_, with: "-") + |> expect.equal(_, "Hello-world!") +} |