Then the "Flagged Orders" widget should list 5 records

Assert the number of rows a table widget (by its heading) shows, or that it lists a record.

Examples

Then the "Flagged Orders" widget should list 5 records
Then the "Flagged Orders" widget should list "WS-TEST-0001"
And the "Latest Orders" widget should list 10 records
Then the "Latest Orders" widget should list "Wendy Webship"
And the "Flagged Orders" widget should list 0 records

Pattern

Then(/^the "([^"]*)" widget should list (?:(\d+) records?|"([^"]*)")$/, …)

Part of @webship-js/filament-steps (github.com/webship/filament-steps), a step pack for Webship-js 2.0.x.