pact: validate that an array contains a matching hash
问题 I have a service that returns an array of hashes, the order of which is non-deterministic. I need to validate that there exists one hash that has a certain key/value, and that hash is populated with data, but the rest of the hashes I don't care about their data. For example, if the service returns this: [ { "key":"meaningless1", "data": { } }, { "key":"meaningless2", "data": { "some": "data", "goes": ["here"] } }, { "key":"meaningful", "data": { "regex": "value", "integer": 1, "boolean": true