From 424fe864ddca0ee61d93aaf9a7864c0587f6f8a0 Mon Sep 17 00:00:00 2001 From: Prarup Gurung Date: Fri, 17 May 2024 12:52:34 +0545 Subject: [PATCH] deleteFileFolder.feature: Used sharingNG for sharing in given step --- tests/acceptance/config/behat-core.yml | 4 ++ .../deleteFileFolder.feature | 48 ++++++++++++++----- 2 files changed, 40 insertions(+), 12 deletions(-) diff --git a/tests/acceptance/config/behat-core.yml b/tests/acceptance/config/behat-core.yml index 1d44780f1a..135a1d58cb 100644 --- a/tests/acceptance/config/behat-core.yml +++ b/tests/acceptance/config/behat-core.yml @@ -301,6 +301,8 @@ default: - TrashbinContext: - PublicWebDavContext: - FilesVersionsContext: + - SpacesContext: + - SharingNgContext: - WebDavPropertiesContext: coreApiWebdavEtagPropagation2: @@ -314,6 +316,8 @@ default: - FilesVersionsContext: - WebDavPropertiesContext: - OcisConfigContext: + - SpacesContext: + - SharingNgContext: extensions: rdx\behatvars\BehatVariablesExtension: ~ diff --git a/tests/acceptance/features/coreApiWebdavEtagPropagation1/deleteFileFolder.feature b/tests/acceptance/features/coreApiWebdavEtagPropagation1/deleteFileFolder.feature index e76f9f9e9a..2d54e1b7d1 100644 --- a/tests/acceptance/features/coreApiWebdavEtagPropagation1/deleteFileFolder.feature +++ b/tests/acceptance/features/coreApiWebdavEtagPropagation1/deleteFileFolder.feature @@ -89,7 +89,12 @@ Feature: propagation of etags when deleting a file or folder And using DAV path And user "Alice" has created folder "/upload/sub" And user "Alice" has uploaded file with content "uploaded content" to "/upload/sub/file.txt" - And user "Alice" has shared folder "/upload" with user "Brian" + And user "Alice" has sent the following resource share invitation: + | resource | upload | + | space | Personal | + | sharee | Brian | + | shareType | user | + | permissionsRole | Editor | And user "Alice" has stored etag of element "/" And user "Alice" has stored etag of element "/upload" And user "Alice" has stored etag of element "/upload/sub" @@ -119,7 +124,12 @@ Feature: propagation of etags when deleting a file or folder And using DAV path And user "Alice" has created folder "/upload/sub" And user "Alice" has uploaded file with content "uploaded content" to "/upload/sub/file.txt" - And user "Alice" has shared folder "/upload" with user "Brian" + And user "Alice" has sent the following resource share invitation: + | resource | upload | + | space | Personal | + | sharee | Brian | + | shareType | user | + | permissionsRole | Editor | And user "Alice" has stored etag of element "/" And user "Alice" has stored etag of element "/upload" And user "Alice" has stored etag of element "/upload/sub" @@ -149,7 +159,12 @@ Feature: propagation of etags when deleting a file or folder And using DAV path And user "Alice" has created folder "/upload/sub" And user "Alice" has created folder "/upload/sub/toDelete" - And user "Alice" has shared folder "/upload" with user "Brian" + And user "Alice" has sent the following resource share invitation: + | resource | upload | + | space | Personal | + | sharee | Brian | + | shareType | user | + | permissionsRole | Editor | And user "Alice" has stored etag of element "/" And user "Alice" has stored etag of element "/upload" And user "Alice" has stored etag of element "/upload/sub" @@ -179,7 +194,12 @@ Feature: propagation of etags when deleting a file or folder And using DAV path And user "Alice" has created folder "/upload/sub" And user "Alice" has created folder "/upload/sub/toDelete" - And user "Alice" has shared folder "/upload" with user "Brian" + And user "Alice" has sent the following resource share invitation: + | resource | upload | + | space | Personal | + | sharee | Brian | + | shareType | user | + | permissionsRole | Editor | And user "Alice" has stored etag of element "/" And user "Alice" has stored etag of element "/upload" And user "Alice" has stored etag of element "/upload/sub" @@ -207,10 +227,12 @@ Feature: propagation of etags when deleting a file or folder Scenario Outline: deleting a file in a publicly shared folder changes its etag for the sharer Given using DAV path And user "Alice" has uploaded file with content "uploaded content" to "/upload/file.txt" - And user "Alice" has created a public link share with settings - | path | upload | - | permissions | change | - | password | %public% | + And using SharingNG + And user "Alice" has created the following resource link share: + | resource | upload | + | space | Personal | + | permissionsRole | edit | + | password | %public% | And user "Alice" has stored etag of element "/" And user "Alice" has stored etag of element "/upload" When the public deletes file "file.txt" from the last public link share using the password "%public%" and new public WebDAV API @@ -233,10 +255,12 @@ Feature: propagation of etags when deleting a file or folder Scenario Outline: deleting a folder in a publicly shared folder changes its etag for the sharer Given using DAV path And user "Alice" has created folder "/upload/sub" - And user "Alice" has created a public link share with settings - | path | upload | - | permissions | change | - | password | %public% | + And using SharingNG + And user "Alice" has created the following resource link share: + | resource | upload | + | space | Personal | + | permissionsRole | edit | + | password | %public% | And user "Alice" has stored etag of element "/" And user "Alice" has stored etag of element "/upload" When the public deletes folder "sub" from the last public link share using the password "%public%" and new public WebDAV API