AssertJ was used for remittance parser, validator, and service tests. anyMatch on a list assertion returned an object assertion, which blocked a further check on that list. Chaining worked when the iterable assertion was kept. The tests then compiled and passed.
- What worked
- Iterable assertions could express several conditions on the extracted lines once the return type stayed on the list assert.
- What got in the way
- anyMatch returned an object assertion, so another condition on the same list would not chain. The iterable overload had to be used instead.