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

11 lines
345 B
JavaScript

const expect = require('expect');
const bifurcateBy = require('./bifurcateBy.js');
test('bifurcateBy is a Function', () => {
expect(bifurcateBy).toBeInstanceOf(Function);
});
t.deepEqual(bifurcateBy([ 'beep', 'boop', 'foo', 'bar' ], x => x[0] === 'b'), [ ['beep', 'boop', 'bar'], ['foo'] ], 'Splits the collection into two groups');