Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
export const toHaveArrayOfObjectsMatcher = (received: any, propPath: string) =>
createResult({
message: () => `expected ${propPath} of ${received} to be an array of objects`,
notMessage: () => `expected ${propPath} of ${received} not to be an array of objects`,
pass: isArrayOfObjects(getIn(propPath.split('.'), received))
});
export const toBeArrayOfObjectsMatcher = (received: any) =>
createResult({
message: () => `expected ${received} to be a non-empty array, containing only objects`,
notMessage: () => `expected ${received} not to be a non-empty array, containing only objects`,
pass: isArrayOfObjects(received)
});