[tests-only][full-ci]Extend tests coverage for different role capability for group (#5742)

* Extend tests coverage for different role capability for group

* Remove unwanted scenario

* Change http status code
This commit is contained in:
Amrita
2023-03-28 09:09:37 +05:45
committed by GitHub
parent 1e5bf171fe
commit 63ba5613c0
8 changed files with 180 additions and 41 deletions
@@ -1,4 +1,4 @@
@api @skipOnOcV10
@api @skipOnOcV10 @issue-5099
Feature: edit group name
As an admin
I want to be able to edit group name
@@ -8,7 +8,7 @@ Feature: edit group name
Given user "Alice" has been created with default attributes and without skeleton files
And the administrator has given "Alice" the role "Admin" using the settings api
@issue-5099
Scenario Outline: admin user renames a group
Given group "<old_group>" has been created
When user "Alice" renames group "<old_group>" to "<new_group>" using the Graph API
@@ -22,4 +22,22 @@ Feature: edit group name
| grp1 | |
| grp1 | $x<=>[y*z^2]! |
| grp1 | staff?group |
| grp1 | 50%pass |
| grp1 | 50%pass |
Scenario Outline: user other than the admin can't rename a group
Given the administrator has given "Alice" the role "<role>" using the settings api
And group "grp1" has been created
When user "Alice" tries to rename group "grp1" to "grp101" using the Graph API
Then the HTTP status code should be "403"
Examples:
| role |
| Space Admin |
| User |
| Guest |
Scenario: admin user tries to rename nonexistent group
When user "Alice" tries to rename a nonexistent group to "grp1" using the Graph API
Then the HTTP status code should be "404"
And group "grp1" should not exist