wip: unit test fixes continued

This commit is contained in:
jdalton
2023-09-21 07:45:49 -07:00
parent bd518dd906
commit a79c5c434c
14 changed files with 66 additions and 77 deletions

View File

@@ -1,5 +1,6 @@
import lodashStable, { ary, curry, rearg } from 'lodash';
import { slice, _ } from './utils';
import lodashStable from 'lodash';
import { slice } from './utils';
import ary from '../src/ary';
describe('ary', () => {
function fn(a, b, c) {
@@ -72,14 +73,4 @@ describe('ary', () => {
expect(actual).toEqual(['a', 'b', 'c']);
});
it('should work when combined with other methods that use metadata', () => {
const array = ['a', 'b', 'c'];
let includes = curry(rearg(ary(_.includes, 2), 1, 0), 2);
expect(includes('b')(array, 2)).toBe(true);
includes = _(_.includes).ary(2).rearg(1, 0).curry(2).value();
expect(includes('b')(array, 2)).toBe(true);
});
});