n8n/packages/nodes-base/nodes/Microsoft/Teams/test/v2/utils.test.ts

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

26 lines
472 B
TypeScript
Raw Normal View History

import { filterSortSearchListItems } from '../../v2/helpers/utils';
describe('Test MicrosoftTeamsV2, filterSortSearchListItems', () => {
it('should filter, sort and search list items', () => {
const items = [
{
name: 'Test1',
value: 'test1',
},
{
name: 'Test2',
value: 'test2',
},
];
const result = filterSortSearchListItems(items, 'test1');
expect(result).toEqual([
{
name: 'Test1',
value: 'test1',
},
]);
});
});