Files
30-seconds-of-code/test/lcm/lcm.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
338 B
JavaScript

const expect = require('expect');
const lcm = require('./lcm.js');
test('lcm is a Function', () => {
expect(lcm).toBeInstanceOf(Function);
});
t.equal(lcm(12, 7), 84, "Returns the least common multiple of two or more numbers.");
t.equal(lcm(...[1, 3, 4, 5]), 60, "Returns the least common multiple of two or more numbers.");