diff --git a/test/features/groups.feature b/test/features/groups.feature index b6070600..15577315 100644 --- a/test/features/groups.feature +++ b/test/features/groups.feature @@ -39,3 +39,28 @@ Feature: Group APIs When I view the "silly-walks" group API "not including" users Then I should see an element with xpath "//*[contains(string(), '"success": true') and contains(string(), '"name": "silly-walks"')]" + + Scenario: As a sysadmin, when I create a group with a long name, it should be preserved + Given "SysAdmin" as the persona + When I log in + And I go to group page + And I click the link to "/group/new" + And I fill in "title" with "Group name more than 35 characters aaaaaaaaaaaa" + # This is actually the URL + And I fill in "name" with "group-name-more-than-30-characters" + And I press the element with xpath "//button[contains(@class, 'btn-primary')]" + And I take a debugging screenshot + # Breadcrumb should be truncated but preserve full name in a tooltip + Then I should see an element with xpath "//ol[contains(@class, 'breadcrumb')]//a[contains(string(), 'Group name more') and contains(string(), '...') and @title = 'Group name more than 35 characters aaaaaaaaaaaa']" + + # Search facets should be truncated but preserve full name in a tooltip + When I create a dataset and resource with key-value parameters "notes=Testing long group name" and "name=Test" + And I press "Groups" + And I select "Group name more than 35 characters aaaaaaaaaaaa" from "group" + And I press the element with xpath "//button[contains(@class, 'btn-primary')]" + Then I should see an element with xpath "//form//a[string() = 'Group name more than 35 characters aaaaaaaaaaaa']" + When I press "Group name more than" + + Then I should see an element with xpath "//li[contains(@class, 'nav-item')]//a[contains(string(), 'Group name more') and contains(string(), '...') and @title = 'Group name more than 35 characters aaaaaaaaaaaa']" + When I press the element with xpath "//li[contains(@class, 'nav-item')]//a[contains(string(), 'Group name more') and contains(string(), '...') and @title = 'Group name more than 35 characters aaaaaaaaaaaa']" + Then I should see an element with xpath "//li[contains(@class, 'nav-item') and contains(@class, 'active')]//a[contains(string(), 'Group name more') and contains(string(), '...') and @title = 'Group name more than 35 characters aaaaaaaaaaaa']"