rickvanlieshout.com/src/utils/to-kebab-case.test.ts
2022-04-16 14:53:32 +00:00

11 lines
401 B
TypeScript

import toKebabCase from "./to-kebab-case";
test("toKebabCase", () => {
expect(toKebabCase()).toBe("");
expect(toKebabCase("lorEm")).toBe("lorem");
expect(toKebabCase("lorem ipsum")).toBe("lorem-ipsum");
expect(toKebabCase("lorem_ipsum")).toBe("lorem-ipsum");
expect(toKebabCase("lorem #ipsum")).toBe("lorem-ipsum");
expect(toKebabCase("Lorem Ipsum Dolor")).toBe("lorem-ipsum-dolor");
});