BDD file with acceptance criteria for sorting the people list by last active, permission or alphabetical.
Feature: As a user I want to sort my team members for my preffered view
Scenario: On the people page viewing default sort
Given I am viewing the people list
Then I should see the people list in alphabetical order
Scenario: Sort options on people page
Given I am viewing the sort options on the people page
Then I will be able to sort by:
| alphabetical |
| permission |
| last active |
Scenario Outline: Remembering last sort
Given my last sort is <sort>
When I go to the people list
Then I can see people ordered by <sort>
Examples:
| sort |
| alphabetical |
| permission |
| last active |
Scenario Outline: Selecting sort
Given I select a <sort> that is the same as my current sort
Then the people list state will persist
And the sort options will close
Examples:
| sort |
| alphabetical |
| permission |
| last active |
Scenario Outline: Changing sort
Given I select a <sort> that is different than my current sort
Then the people list will update to be sorted by <sort>
And the sort options will close
Examples:
| sort |
| alphabetical |
| permission |
| last active |
Scenario: No people in the list
Given I have no people in the list to be sorted
Then sort will be disabled