diff options
author | Mathias Jean Johansen <mathias@mjj.io> | 2022-05-02 17:00:26 +0200 |
---|---|---|
committer | Louis Pilfold <louis@lpil.uk> | 2022-05-04 22:08:15 +0100 |
commit | e85d977985e48dd5f76db564ee8e978a3118bb20 (patch) | |
tree | c0b9e496154392e5fb0e0e149856202f932d556d /test | |
parent | a8f009dc294d55b12f29c32afbdd3b3a43582f75 (diff) | |
download | gleam_stdlib-e85d977985e48dd5f76db564ee8e978a3118bb20.tar.gz gleam_stdlib-e85d977985e48dd5f76db564ee8e978a3118bb20.zip |
Add tests using unicode strings.
Diffstat (limited to 'test')
-rw-r--r-- | test/gleam/string_test.gleam | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/gleam/string_test.gleam b/test/gleam/string_test.gleam index 14b034c..31c93ad 100644 --- a/test/gleam/string_test.gleam +++ b/test/gleam/string_test.gleam @@ -373,6 +373,10 @@ pub fn first_test() { "gleam" |> string.first |> should.equal(Some("g")) + + "⭐️ Gleam" + |> string.first + |> should.equal(Some("⭐️")) } pub fn last_test() { @@ -387,6 +391,10 @@ pub fn last_test() { "gleam " |> string.last |> should.equal(Some(" ")) + + "եոգլի" + |> string.last + |> should.equal(Some("ի")) } pub fn capitalize_test() { @@ -417,4 +425,8 @@ pub fn capitalize_test() { " gLeAm1" |> string.capitalize |> should.equal(" gleam1") + + "る" + |> string.capitalize + |> should.equal("る") } |