summaryrefslogtreecommitdiff
path: root/tests/modules
diff options
context:
space:
mode:
authorSaikari <[email protected]>2026-01-17 02:33:18 +0300
committerSaikari <[email protected]>2026-01-17 02:33:18 +0300
commit3cf298b854443e7bbb2a96d976e8d79ffc4ddf02 (patch)
tree6ba730d06b06b04136f536b5548278f8f42751a7 /tests/modules
parent4d9a7aeaaf2732ee846ee452f46370a29b6de038 (diff)
add string case conversion functions: lower and upper
Diffstat (limited to 'tests/modules')
-rw-r--r--tests/modules/string/test.lua7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/modules/string/test.lua b/tests/modules/string/test.lua
index 3f52dc593..6bb3b6f78 100644
--- a/tests/modules/string/test.lua
+++ b/tests/modules/string/test.lua
@@ -106,3 +106,10 @@ function test_replace(t)
t:are_equal(("123$xyz456xyz789xyz"):replace("123$", "000", {plain = true}), "000xyz456xyz789xyz")
t:are_equal(("123xyz$456xyz$789xyz$"):replace("xyz$", "000", {plain = true}), "123000456000789000")
end
+
+function test_case(t)
+ t:are_equal(("Hello"):lower(), "hello")
+ t:are_equal(("Hello"):upper(), "HELLO")
+ t:are_equal(("Звезда Хэнсин"):lower(), "звезда хэнсин")
+ t:are_equal(("Звезда Хэнсин"):upper(), "ЗВЕЗДА ХЭНСИН")
+end