Scenario: Events should be listed in chronological order by event date in ASC order
How do i test this scenario in cucumber? Events has a name and a event_date. Events is shown in a list in the GUI. I want the test to fail when the events is in a unsorted order and the test to pass when the list is sorted by event_date ASC order.
The real problem is how to define the following step
Then /^I should see a list that has the first element "([^\"]*)"$/ do |element| ???????????????????????????????????????????????
end