Asserts (soft) that items are ordered by a date field. Reports every out-of-order pair.
the items, in the order received
the date field on each item
"desc" (newest first) or "asc". Default "desc"
"desc"
"asc"
how the dates are written
Optional
dayjs format of the dates. Default: ISO 8601
expectSortedByDate(body.items, "publishedAt", "desc"); Copy
expectSortedByDate(body.items, "publishedAt", "desc");
Asserts (soft) that items are ordered by a date field. Reports every out-of-order pair.