Skip to content

Commit f632802

Browse files
Merge pull request #10798 from owncloud/delete-group-share
[tests-only][full-ci]added test to delete share access from group after the share role has been disabled
2 parents d9bfdda + 48b11e0 commit f632802

File tree

2 files changed

+106
-0
lines changed

2 files changed

+106
-0
lines changed

tests/acceptance/features/apiSharingNg1/removeAccessToDrive.feature

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -262,3 +262,21 @@ Feature: Remove access to a drive
262262
When user "Alice" removes the access of user "Brian" from space "new-space" using root endpoint of the Graph API
263263
Then the HTTP status code should be "204"
264264
And the user "Brian" should not have a space called "NewSpace"
265+
266+
@env-config
267+
Scenario: remove space share from group after the share role Space Editor Without Versions has been disabled
268+
Given using spaces DAV path
269+
And the administrator has enabled the permissions role "Space Editor Without Versions"
270+
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
271+
And user "Alice" has created a space "new-space" with the default quota using the Graph API
272+
And group "group1" has been created
273+
And user "Brian" has been added to group "group1"
274+
And user "Alice" has sent the following space share invitation:
275+
| space | new-space |
276+
| sharee | group1 |
277+
| shareType | group |
278+
| permissionsRole | Space Editor Without Versions |
279+
And the administrator has disabled the permissions role "Space Editor Without Versions"
280+
When user "Alice" removes the access of group "group1" from space "new-space" using root endpoint of the Graph API
281+
Then the HTTP status code should be "204"
282+
And the user "Brian" should not have a space called "new-space"

tests/acceptance/features/apiSharingNg1/removeAccessToDriveItem.feature

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -223,3 +223,91 @@ Feature: Remove access to a drive item
223223
Then the HTTP status code should be "204"
224224
And for user "Brian" the space "Shares" should not contain these entries:
225225
| folderToShare |
226+
227+
@env-config
228+
Scenario Outline: remove share from group after the share role Secure Viewer has been disabled (Personal Space)
229+
Given the administrator has enabled the permissions role "Secure Viewer"
230+
And group "group1" has been created
231+
And user "Brian" has been added to group "group1"
232+
And user "Alice" has uploaded file with content "some content" to "textfile.txt"
233+
And user "Alice" has created folder "folderToShare"
234+
And user "Alice" has sent the following resource share invitation:
235+
| resource | <resource> |
236+
| space | Personal |
237+
| sharee | group1 |
238+
| shareType | group |
239+
| permissionsRole | Secure Viewer |
240+
And the administrator has disabled the permissions role "Secure Viewer"
241+
When user "Alice" removes the access of group "group1" from resource "<resource>" of space "Personal" using the Graph API
242+
Then the HTTP status code should be "204"
243+
And for user "Brian" the space "Shares" should not contain these entries:
244+
| <resource> |
245+
Examples:
246+
| resource |
247+
| textfile.txt |
248+
| folderToShare |
249+
250+
@env-config
251+
Scenario: remove share from group after the share role Denied has been disabled (Personal Space)
252+
Given the administrator has enabled the permissions role "Denied"
253+
And group "group1" has been created
254+
And user "Brian" has been added to group "group1"
255+
And user "Alice" has created folder "folderToShare"
256+
And user "Alice" has sent the following resource share invitation:
257+
| resource | folderToShare |
258+
| space | Personal |
259+
| sharee | group1 |
260+
| shareType | group |
261+
| permissionsRole | Denied |
262+
And the administrator has disabled the permissions role "Denied"
263+
When user "Alice" removes the access of group "group1" from resource "folderToShare" of space "Personal" using the Graph API
264+
Then the HTTP status code should be "204"
265+
And for user "Brian" the space "Shares" should not contain these entries:
266+
| folderToShare |
267+
268+
@env-config
269+
Scenario Outline: remove share from group after the share role Secure Viewer has been disabled (Project Space)
270+
Given using spaces DAV path
271+
And the administrator has enabled the permissions role "Secure Viewer"
272+
And group "group1" has been created
273+
And user "Brian" has been added to group "group1"
274+
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
275+
And user "Alice" has created a space "new-space" with the default quota using the Graph API
276+
And user "Alice" has uploaded a file inside space "new-space" with content "some content" to "textfile.txt"
277+
And user "Alice" has created a folder "folderToShare" in space "new-space"
278+
And user "Alice" has sent the following resource share invitation:
279+
| resource | <resource> |
280+
| space | new-space |
281+
| sharee | group1 |
282+
| shareType | group |
283+
| permissionsRole | Secure Viewer |
284+
And the administrator has disabled the permissions role "Secure Viewer"
285+
When user "Alice" removes the access of group "group1" from resource "<resource>" of space "new-space" using the Graph API
286+
Then the HTTP status code should be "204"
287+
And for user "Brian" the space "Shares" should not contain these entries:
288+
| <resource> |
289+
Examples:
290+
| resource |
291+
| textfile.txt |
292+
| folderToShare |
293+
294+
@env-config
295+
Scenario: remove share from group after the share role Denied has been disabled (Project Space)
296+
Given using spaces DAV path
297+
And the administrator has enabled the permissions role "Denied"
298+
And group "group1" has been created
299+
And user "Brian" has been added to group "group1"
300+
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
301+
And user "Alice" has created a space "new-space" with the default quota using the Graph API
302+
And user "Alice" has created a folder "folderToShare" in space "new-space"
303+
And user "Alice" has sent the following resource share invitation:
304+
| resource | folderToShare |
305+
| space | new-space |
306+
| sharee | group1 |
307+
| shareType | group |
308+
| permissionsRole | Denied |
309+
And the administrator has disabled the permissions role "Denied"
310+
When user "Alice" removes the access of group "group1" from resource "folderToShare" of space "new-space" using the Graph API
311+
Then the HTTP status code should be "204"
312+
And for user "Brian" the space "Shares" should not contain these entries:
313+
| folderToShare |

0 commit comments

Comments
 (0)