From 472a21b2f013f0f4578550c3ba81b0811fdd88ea Mon Sep 17 00:00:00 2001 From: Mylloon Date: Fri, 27 Sep 2024 14:53:37 +0200 Subject: [PATCH] string test --- tests/modules/string.test.ts | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 tests/modules/string.test.ts diff --git a/tests/modules/string.test.ts b/tests/modules/string.test.ts new file mode 100644 index 0000000..06e45e8 --- /dev/null +++ b/tests/modules/string.test.ts @@ -0,0 +1,28 @@ +import "../../src/modules/string"; + +describe("Capitalize", () => { + { + const name = "test"; + test(name, () => { + expect(name.capitalize()).toBe("Test"); + }); + } + { + const name = "MACHIN"; + test(name, () => { + expect(name.capitalize()).toBe("MACHIN"); + }); + } + { + const name = "tRUC"; + test(name, () => { + expect(name.capitalize()).toBe("TRUC"); + }); + } + { + const name = "Super"; + test(name, () => { + expect(name.capitalize()).toBe("Super"); + }); + } +});