odin-javascript-exercises/snakeCase/snakeCase.spec.js
Tatiana e691edc97c Revert "Merge pull request #1 from xandora/jester-tester"
This reverts commit e901090896, reversing
changes made to 42076e7424.
2021-05-08 11:28:50 -07:00

26 lines
872 B
JavaScript

const snakeCase = require('./snakeCase')
describe("snakeCase", function () {
it("works with simple lowercased phrases", function () {
expect(snakeCase("hello world")).toEqual("hello_world");
});
xit("works with Caps and punctuation", function () {
expect(snakeCase("Hello, World???")).toEqual("hello_world");
});
xit("works with longer phrases", function () {
expect(snakeCase("This is the song that never ends....")).toEqual(
"this_is_the_song_that_never_ends"
);
});
xit("works with camel case", function () {
expect(snakeCase("snakeCase")).toEqual("snake_case");
});
xit("works with kebab case", function () {
expect(snakeCase("snake-case")).toEqual("snake_case");
});
xit("works with WTF case", function () {
expect(snakeCase("SnAkE..CaSe..Is..AwEsOmE")).toEqual(
"snake_case_is_awesome"
);
});
});