Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
it('should move a field - less', () => {
const res = arrayMove('flat', 3, 1)(fields);
expect(res['flat.0']).toBe(field0);
expect(res['flat.1']).toBe(field3);
expect(res['flat.2']).toBe(field1);
expect(res['flat.3']).toBe(field2);
expect(res['flat.4']).toBe(field4);
});