x/rambda/source/maxBy.spec.js
1234567891011import {maxBy} from './maxBy'test('happy', () => { expect(maxBy(Math.abs, -5, 2)).toEqual(-5)})test('curried', () => { expect(maxBy(Math.abs)(2, -5)).toEqual(-5) expect(maxBy(Math.abs)(2)(-5)).toEqual(-5)})