diff --git a/test/std/string/camel_case_test.ds b/test/std/string/camel_case_test.ds new file mode 100644 index 0000000..dc19d9c --- /dev/null +++ b/test/std/string/camel_case_test.ds @@ -0,0 +1,12 @@ + +fn test_without_symbols + output = camel_case "hello world 22" + + assert_eq ${output} "HelloWorld22" +end + +fn test_with_symbols + output = camel_case "hello!@#$% world^&*()[]{}22" + + assert_eq ${output} "HelloWorld22" +end diff --git a/test/std/string/snake_case_test.ds b/test/std/string/snake_case_test.ds new file mode 100644 index 0000000..1ee9947 --- /dev/null +++ b/test/std/string/snake_case_test.ds @@ -0,0 +1,12 @@ + +fn test_without_symbols + output = snake_case "hello world 22" + + assert_eq ${output} "hello_world_22" +end + +fn test_with_symbols + output = snake_case "hello!@#$% world^&*()[]{}22" + + assert_eq ${output} "hello_world_22" +end