n8n/packages/nodes-base/nodes/Microsoft/Teams/test/v2/utils.test.ts
Michael Kret 2c146cca62
feat(Microsoft Teams Node): Overhaul (#7477)
Co-authored-by: Giulio Andreini <andreini@netseven.it>
2024-01-22 18:35:09 +02:00

26 lines
472 B
TypeScript

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',
},
]);
});
});