Files
dancing-summarizer/util_string_test.ts
2025-06-05 23:25:27 +02:00

12 lines
495 B
TypeScript

import { assertEquals } from "@std/assert/equals";
import { camelToTitleCase } from "./util_string.ts";
Deno.test("camelToTitleCase transforms camelCase to Title Case", () => {
assertEquals(camelToTitleCase("thisIsATest"), "This Is a Test");
assertEquals(camelToTitleCase("denoIsAwesome"), "Deno Is Awesome");
assertEquals(camelToTitleCase("helloWorld"), "Hello World");
});
Deno.test("camelToTitleCase handles empty string", () => {
assertEquals(camelToTitleCase(""), "");
});