Files
30-seconds-of-code/test/palindrome/palindrome.test.js
Angelos Chalaris 4f7da1be9b Test migration to jest by hand
Apparently using regular expressions is way easier.
2018-06-18 15:15:56 +03:00

11 lines
329 B
JavaScript

const expect = require('expect');
const palindrome = require('./palindrome.js');
test('palindrome is a Function', () => {
expect(palindrome).toBeInstanceOf(Function);
});
t.equal(palindrome('taco cat'), true, "Given string is a palindrome");
t.equal(palindrome('foobar'), false, "Given string is not a palindrome");