jest mongoose match array of objects code example
Example: jest check array of objects
test('id should match', () => {
const obj = {
id: '111',
productName: 'Jest Handbook',
url: 'https://jesthandbook.com'
};
expect(obj.id).toEqual('111');
});