Merge pull request #178 from opencloud-eu/cleanpTests

clean up tests
This commit is contained in:
Viktor Scharf
2025-02-11 12:26:05 +01:00
committed by GitHub
17 changed files with 85 additions and 1011 deletions
@@ -81,17 +81,8 @@ Feature: get users
"""
Examples:
| user-role | user-role-2 |
| Space Admin | Space Admin |
| Space Admin | User |
| Space Admin | User Light |
| Space Admin | Admin |
| User | Space Admin |
| User | User |
| User | User Light |
| User | Admin |
| User Light | Space Admin |
| User Light | User |
| User Light | User Light |
| User Light | Admin |
@@ -634,17 +625,8 @@ Feature: get users
"""
Examples:
| user-role | user-role-2 |
| Space Admin | Space Admin |
| Space Admin | User |
| Space Admin | User Light |
| Space Admin | Admin |
| User | Space Admin |
| User | User |
| User | User Light |
| User | Admin |
| User Light | Space Admin |
| User Light | User |
| User Light | User Light |
| User Light | Admin |
@@ -174,7 +174,6 @@ Feature: Remove access to a drive
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario: user removes internal link share from project space using root endpoint
@@ -203,7 +202,6 @@ Feature: Remove access to a drive
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario: user tries to remove internal link share of project space owned by next user using root endpoint
@@ -233,7 +231,6 @@ Feature: Remove access to a drive
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario: user removes internal link share of a project drive using permissions endpoint
@@ -24,7 +24,6 @@ Feature: Remove access to a drive item
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario Outline: user removes access to a file in link share
@@ -40,7 +39,6 @@ Feature: Remove access to a drive item
| permissions-role |
| view |
| edit |
| blocksDownload |
Scenario Outline: user removes access to a folder in project space in link share
@@ -60,7 +58,6 @@ Feature: Remove access to a drive item
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario Outline: user removes access to a file in project space in link share
@@ -78,4 +75,3 @@ Feature: Remove access to a drive item
| permissions-role |
| view |
| edit |
| blocksDownload |
@@ -69,7 +69,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
@issue-8619
Scenario: create an internal link share of a folder using permissions endpoint
@@ -199,7 +198,6 @@ Feature: Create a link share for a resource
| permissions-role |
| view |
| edit |
| blocksDownload |
@issue-8619
Scenario: create an internal link share of a file using permissions endpoint
@@ -337,7 +335,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
@issue-7879
Scenario Outline: create a link share of a file with display name and expiry date using permissions endpoint
@@ -406,7 +403,6 @@ Feature: Create a link share for a resource
| permissions-role |
| view |
| edit |
| blocksDownload |
@env-config @issue-7879
Scenario Outline: create a link share of a file without password using permissions endpoint
@@ -472,7 +468,6 @@ Feature: Create a link share for a resource
| view |
| edit |
| internal |
| blocksDownload |
@env-config @issue-9724 @issue-10331
Scenario: set password on a file's link share using permissions endpoint
@@ -505,7 +500,7 @@ Feature: Create a link share for a resource
"""
And the public should be able to download file "textfile1.txt" from the last link share with password "%public%" and the content should be "other data"
@skip-local-run
Scenario Outline: create a file's link share with a password that is listed in the Banned-Password-List using permissions endpoint
Given the config "OC_PASSWORD_POLICY_BANNED_PASSWORDS_LIST" has been set to path "config/drone/banned-password-list.txt"
And user "Alice" has uploaded file with content "other data" to "text.txt"
@@ -614,7 +609,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario: create an internal link share of a folder inside project-space using permissions endpoint
@@ -760,9 +754,8 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
@skip-local-run
Scenario Outline: create a link share of a folder inside project-space with a password that is listed in the Banned-Password-List using permissions endpoint
Given the config "OC_PASSWORD_POLICY_BANNED_PASSWORDS_LIST" has been set to path "config/drone/banned-password-list.txt"
And using spaces DAV path
@@ -816,9 +809,6 @@ Feature: Create a link share for a resource
| 123 | createOnly |
| password | createOnly |
| OpenCloud | createOnly |
| 123 | blocksDownload |
| password | blocksDownload |
| OpenCloud | blocksDownload |
@env-config @issue-7879
Scenario Outline: create a link share of a file inside project-space without password using permissions endpoint
@@ -888,7 +878,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
@issue-7879
Scenario Outline: create a link share of a file inside project-space using permissions endpoint
@@ -954,7 +943,6 @@ Feature: Create a link share for a resource
| permissions-role |
| view |
| edit |
| blocksDownload |
@issue-8619
Scenario: create an internal link share of a file inside project-space using permissions endpoint
@@ -1098,7 +1086,6 @@ Feature: Create a link share for a resource
| permissions-role |
| view |
| edit |
| blocksDownload |
@env-config @issue-7879
Scenario Outline: create a link share of a file inside project-space without password using permissions endpoint
@@ -1167,9 +1154,8 @@ Feature: Create a link share for a resource
| view |
| edit |
| internal |
| blocksDownload |
@skip-local-run
Scenario Outline: create a link share of a file inside project-space with a password that is listed in the Banned-Password-List using permissions endpoint
Given the config "OC_PASSWORD_POLICY_BANNED_PASSWORDS_LIST" has been set to path "config/drone/banned-password-list.txt"
And using spaces DAV path
@@ -1217,9 +1203,6 @@ Feature: Create a link share for a resource
| 123 | edit |
| password | edit |
| OpenCloud | edit |
| 123 | blocksDownload |
| password | blocksDownload |
| OpenCloud | blocksDownload |
@env-config @issue-9724 @issue-10331
Scenario: set password on a existing link share of a file inside project-space using permissions endpoint
@@ -1300,12 +1283,10 @@ Feature: Create a link share for a resource
| edit | Shares | no share permission |
| upload | Shares | no share permission |
| createOnly | Shares | no share permission |
| blocksDownload | Shares | invalid link type |
| view | Personal | cannot create link on personal space root |
| edit | Personal | cannot create link on personal space root |
| upload | Personal | cannot create link on personal space root |
| createOnly | Personal | cannot create link on personal space root |
| blocksDownload | Personal | invalid link type |
@issue-7879
Scenario Outline: create a link share of a project-space drive using permissions endpoint
@@ -1371,7 +1352,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario Outline: try to create an internal link share of a Personal and Shares drives using permissions endpoint
@@ -1629,9 +1609,8 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
@skip-local-run
Scenario Outline: try to create a link share of a project-space with a password that is listed in the Banned-Password-List using permissions endpoint
Given the config "OC_PASSWORD_POLICY_BANNED_PASSWORDS_LIST" has been set to path "config/drone/banned-password-list.txt"
And using spaces DAV path
@@ -1683,9 +1662,6 @@ Feature: Create a link share for a resource
| 123 | createOnly |
| password | createOnly |
| OpenCloud | createOnly |
| 123 | blocksDownload |
| password | blocksDownload |
| OpenCloud | blocksDownload |
Scenario Outline: create a link share of a project-space without password using permissions endpoint
@@ -1753,7 +1729,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario Outline: create a quick link share of a folder using permissions endpoint
@@ -1819,7 +1794,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario: create an internal quick link share of a folder using permissions endpoint
@@ -1941,7 +1915,6 @@ Feature: Create a link share for a resource
| permissions-role |
| view |
| edit |
| blocksDownload |
Scenario: create an internal quick link share of a file using permissions endpoint
@@ -2068,7 +2041,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario: create an internal quick link share of a folder inside project-space using permissions endpoint
@@ -2195,7 +2167,6 @@ Feature: Create a link share for a resource
| permissions-role |
| view |
| edit |
| blocksDownload |
@issue-8619
Scenario: create an internal quick link share of a file inside project-space using permissions endpoint
@@ -2323,7 +2294,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario: create an internal quick link share of a project-space using permissions endpoint
@@ -70,11 +70,7 @@ Feature: Update a link share for a resource
Examples:
| permissions-role | new-permissions-role |
| view | edit |
| view | blocksDownload |
| edit | view |
| edit | blocksDownload |
| blocksDownload | edit |
| blocksDownload | blocksDownload |
@issue-8619
Scenario Outline: update role of a file's to internal link share using permissions endpoint
@@ -140,7 +136,6 @@ Feature: Update a link share for a resource
| permissions-role |
| view |
| edit |
| blocksDownload |
Scenario: update expiration date of a file's link share using permissions endpoint
@@ -235,7 +230,7 @@ Feature: Update a link share for a resource
And the public should be able to download file "textfile1.txt" from the last link share with password "%public%" and the content should be "other data"
And the public download of file "textfile1.txt" from the last link share with password "$heLlo*1234*" should fail with HTTP status code "401" using shareNg
@skip-local-run
Scenario Outline: update a file's link share with a password that is listed in the Banned-Password-List using permissions endpoint
Given the config "OC_PASSWORD_POLICY_BANNED_PASSWORDS_LIST" has been set to path "config/drone/banned-password-list.txt"
And user "Alice" has uploaded file with content "other data" to "text.txt"
@@ -402,7 +397,6 @@ Feature: Update a link share for a resource
| createOnly | view |
| createOnly | edit |
| createOnly | upload |
| blocksDownload | blocksDownload |
Scenario Outline: update role of a folder's link share inside project-space using permissions endpoint
@@ -789,7 +783,6 @@ Feature: Update a link share for a resource
| createOnly | view |
| createOnly | edit |
| createOnly | upload |
| blocksDownload | blocksDownload |
@issues-8405
Scenario Outline: remove expiration date of a resource link share using permissions endpoint
@@ -51,12 +51,10 @@ Feature: Create a link share for a resource
| edit | Shares |
| upload | Shares |
| createOnly | Shares |
| blocksDownload | Shares |
| view | Personal |
| edit | Personal |
| upload | Personal |
| createOnly | Personal |
| blocksDownload | Personal |
Scenario Outline: try to create an internal link share of a Personal and Share drives using root endpoint
@@ -209,7 +207,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario: create an internal link share of a project-space using root endpoint
@@ -349,9 +346,8 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
@issue-7879
@issue-7879 @skip-local-run
Scenario Outline: try to create a link share of a project-space drive with a password that is listed in the Banned-Password-List using root endpoint
Given the config "OC_PASSWORD_POLICY_BANNED_PASSWORDS_LIST" has been set to path "config/drone/banned-password-list.txt"
And using spaces DAV path
@@ -403,9 +399,6 @@ Feature: Create a link share for a resource
| 123 | createOnly |
| password | createOnly |
| OpenCloud | createOnly |
| 123 | blocksDownload |
| password | blocksDownload |
| OpenCloud | blocksDownload |
@env-config @issue-7879
Scenario Outline: create a link share of a project-space drive without password using root endpoint
@@ -473,7 +466,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
@issue-7879
Scenario Outline: create a link share of a project-space drive with display name using root endpoint
@@ -540,7 +532,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
@issue-7879
Scenario Outline: create a link share of a project-space drive with expiry date using root endpoint
@@ -611,7 +602,6 @@ Feature: Create a link share for a resource
| edit |
| upload |
| createOnly |
| blocksDownload |
Scenario Outline: create quick link share of a project space drive using root endpoint
@@ -1,493 +0,0 @@
@issue-2914 @skipOnReva
Feature: file versions remember the author of each version
As a user
I want to know the author of each version of a file
So that I can better understand the version history and choose a version to restore
Background:
Given using OCS API version "2"
And user "Alice" has been created with default attributes
And user "Brian" has been created with default attributes
And user "Carol" has been created with default attributes
Scenario: enable file versioning and check the history of changes from multiple users
Given user "David" has been created with default attributes
And user "Alice" has created folder "/test"
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | Editor |
And user "Brian" has a share "test" synced
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | Carol |
| shareType | user |
| permissionsRole | Editor |
And user "Carol" has a share "test" synced
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | David |
| shareType | user |
| permissionsRole | Editor |
And user "David" has a share "test" synced
And user "Alice" has uploaded file with content "uploaded content alice" to "/test/textfile0.txt"
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/test/textfile0.txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/test/textfile0.txt"
And user "David" has uploaded file with content "uploaded content david" to "/Shares/test/textfile0.txt"
When user "Alice" gets the number of versions of file "/test/textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "3"
And the content of version index "1" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content carol"
And the content of version index "2" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content brian"
And the content of version index "3" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content alice"
And as users "Alice" the authors of the versions of file "/test/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Brian |
| 3 | Alice |
And as users "Brian,Carol,David" the authors of the versions of file "/Shares/test/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Brian |
| 3 | Alice |
Scenario: enable file versioning and check the history of changes from multiple users for shared folder in the group
Given user "Alice" has created folder "/test"
And group "grp1" has been created
And user "Alice" has been added to group "grp1"
And user "Brian" has been added to group "grp1"
And user "Carol" has been added to group "grp1"
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | grp1 |
| shareType | group |
| permissionsRole | Editor |
And user "Brian" has a share "test" synced
And user "Carol" has a share "test" synced
And user "Alice" has uploaded file with content "uploaded content alice" to "/test/textfile0.txt"
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/test/textfile0.txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/test/textfile0.txt"
When user "Alice" gets the number of versions of file "/test/textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "2"
And the content of version index "1" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content brian"
And the content of version index "2" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content alice"
And as users "Alice" the authors of the versions of file "/test/textfile0.txt" should be:
| index | author |
| 1 | Brian |
| 2 | Alice |
And as users "Brian,Carol" the authors of the versions of file "/Shares/test/textfile0.txt" should be:
| index | author |
| 1 | Brian |
| 2 | Alice |
Scenario: enable file versioning and check the history of changes from multiple users for shared file in the group
Given group "grp1" has been created
And user "Alice" has been added to group "grp1"
And user "Brian" has been added to group "grp1"
And user "Carol" has been added to group "grp1"
And user "Alice" has uploaded file with content "uploaded content alice" to "/textfile0.txt"
And user "Alice" has sent the following resource share invitation:
| resource | textfile0.txt |
| space | Personal |
| sharee | grp1 |
| shareType | group |
| permissionsRole | File Editor |
And user "Brian" has a share "textfile0.txt" synced
And user "Carol" has a share "textfile0.txt" synced
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/textfile0.txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/textfile0.txt"
When user "Alice" gets the number of versions of file "textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "2"
And the content of version index "1" of file "/textfile0.txt" for user "Alice" should be "uploaded content brian"
And the content of version index "2" of file "/textfile0.txt" for user "Alice" should be "uploaded content alice"
And as users "Alice" the authors of the versions of file "/textfile0.txt" should be:
| index | author |
| 1 | Brian |
| 2 | Alice |
And as users "Brian,Carol" the authors of the versions of file "/Shares/textfile0.txt" should be:
| index | author |
| 1 | Brian |
| 2 | Alice |
Scenario: enable file versioning and check the history of changes from multiple users while moving file in/out of a subfolder
Given user "Alice" has created folder "/test"
And group "grp1" has been created
And user "Alice" has been added to group "grp1"
And user "Brian" has been added to group "grp1"
And user "Carol" has been added to group "grp1"
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | grp1 |
| shareType | group |
| permissionsRole | Editor |
And user "Brian" has a share "test" synced
And user "Carol" has a share "test" synced
And user "Alice" has uploaded file with content "uploaded content alice" to "/test/textfile0.txt"
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/test/textfile0.txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/test/textfile0.txt"
And user "Alice" has moved file "/test/textfile0.txt" to "/textfile0.txt"
And user "Alice" has uploaded file with content "uploaded content alice after moving file outside subfolder" to "/textfile0.txt"
And user "Alice" has moved file "/textfile0.txt" to "/test/textfile0.txt"
When user "Alice" gets the number of versions of file "/test/textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "3"
And the content of version index "1" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content carol"
And the content of version index "2" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content brian"
And the content of version index "3" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content alice"
And as users "Alice" the authors of the versions of file "/test/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Brian |
| 3 | Alice |
And as users "Brian,Carol" the authors of the versions of file "/Shares/test/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Brian |
| 3 | Alice |
Scenario: enable file versioning and check the history of changes from multiple users after renaming file by sharer
Given group "grp1" has been created
And user "Alice" has been added to group "grp1"
And user "Brian" has been added to group "grp1"
And user "Carol" has been added to group "grp1"
And user "Alice" has uploaded file with content "uploaded content alice" to "/exist.txt"
And user "Alice" has sent the following resource share invitation:
| resource | exist.txt |
| space | Personal |
| sharee | grp1 |
| shareType | group |
| permissionsRole | File Editor |
And user "Brian" has a share "exist.txt" synced
And user "Carol" has a share "exist.txt" synced
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/exist.txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/exist.txt"
And user "Alice" has moved file "/exist.txt" to "/textfile0.txt"
When user "Alice" gets the number of versions of file "textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "2"
And the content of version index "1" of file "/textfile0.txt" for user "Alice" should be "uploaded content brian"
And the content of version index "2" of file "/textfile0.txt" for user "Alice" should be "uploaded content alice"
And as user "Alice" the authors of the versions of file "/textfile0.txt" should be:
| index | author |
| 1 | Brian |
| 2 | Alice |
And as users "Brian,Carol" the authors of the versions of file "/Shares/exist.txt" should be:
| index | author |
| 1 | Brian |
| 2 | Alice |
@issue-7555
Scenario: enable file versioning and check the history of changes in sharer after renaming file by sharee
Given group "grp1" has been created
And user "Alice" has been added to group "grp1"
And user "Brian" has been added to group "grp1"
And user "Carol" has been added to group "grp1"
And user "Alice" has uploaded file with content "uploaded content alice" to "/exist.txt"
And user "Alice" has sent the following resource share invitation:
| resource | exist.txt |
| space | Personal |
| sharee | grp1 |
| shareType | group |
| permissionsRole | File Editor |
And user "Brian" has a share "exist.txt" synced
And user "Carol" has a share "exist.txt" synced
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/exist.txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/exist.txt"
And user "Brian" has moved file "/Shares/exist.txt" to "/Shares/textfile0.txt"
When user "Alice" gets the number of versions of file "exist.txt"
Then the HTTP status code should be "207"
And the number of versions should be "2"
And the content of version index "1" of file "/exist.txt" for user "Alice" should be "uploaded content brian"
And the content of version index "2" of file "/exist.txt" for user "Alice" should be "uploaded content alice"
And as users "Alice" the authors of the versions of file "/exist.txt" should be:
| index | author |
| 1 | Brian |
| 2 | Alice |
And as users "Carol" the authors of the versions of file "/Shares/exist.txt" should be:
| index | author |
| 1 | Brian |
| 2 | Alice |
And as user "Brian" the authors of the versions of file "/Shares/textfile0.txt" should be:
| index | author |
| 1 | Brian |
| 2 | Alice |
Scenario: enable file versioning and check the history of changes from multiple users when reshared after unshared by sharer
Given user "Alice" has created folder "/test"
And group "grp1" has been created
And user "Alice" has been added to group "grp1"
And user "Brian" has been added to group "grp1"
And user "Carol" has been added to group "grp1"
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | grp1 |
| shareType | group |
| permissionsRole | Editor |
And user "Brian" has a share "test" synced
And user "Carol" has a share "test" synced
And user "Alice" has uploaded file with content "uploaded content alice" to "/test/textfile0.txt"
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/test/textfile0.txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/test/textfile0.txt"
And user "Alice" has deleted the last share
And user "Alice" has uploaded file with content "uploaded content alice after unshared folder" to "/test/textfile0.txt"
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | grp1 |
| shareType | group |
| permissionsRole | Editor |
And user "Brian" has a share "test" synced
And user "Carol" has a share "test" synced
When user "Alice" gets the number of versions of file "/test/textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "3"
And the content of version index "1" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content carol"
And the content of version index "2" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content brian"
And the content of version index "3" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content alice"
And as users "Alice" the authors of the versions of file "/test/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Brian |
| 3 | Alice |
And as users "Brian,Carol" the authors of the versions of file "/Shares/test/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Brian |
| 3 | Alice |
Scenario: enable file versioning and check the history of changes from multiple users who have a matching folder/file
Given user "David" has been created with default attributes
And user "Brian" has created folder "/test"
And user "Brian" has uploaded file with content "duplicate brian" to "/test/textfile0.txt"
And user "Brian" has uploaded file with content "overwrite brian" to "/test/textfile0.txt"
And user "Brian" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | Carol |
| shareType | user |
| permissionsRole | Editor |
And user "Carol" has a share "test" synced
And user "Brian" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | David |
| shareType | user |
| permissionsRole | Editor |
And user "David" has a share "test" synced
And user "Carol" has created folder "/test"
And user "Carol" has uploaded file with content "duplicate carol" to "/test/textfile0.txt"
And user "Carol" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | Editor |
And user "Brian" has a share "test" synced
And user "Alice" has created folder "/test"
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | Editor |
And user "Brian" has a share "test (1)" synced
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | Carol |
| shareType | user |
| permissionsRole | Editor |
And user "Carol" has a share "test (1)" synced
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | David |
| shareType | user |
| permissionsRole | Editor |
And user "David" has a share "test (1)" synced
And user "Alice" has uploaded file with content "uploaded content alice" to "/test/textfile0.txt"
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/test (1)/textfile0.txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/test (1)/textfile0.txt"
And user "David" has uploaded file with content "uploaded content david" to "/Shares/test (1)/textfile0.txt"
When user "Alice" gets the number of versions of file "/test/textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "3"
And the content of version index "1" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content carol"
And the content of version index "2" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content brian"
And the content of version index "3" of file "/test/textfile0.txt" for user "Alice" should be "uploaded content alice"
And as users "Alice" the authors of the versions of file "/test/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Brian |
| 3 | Alice |
And as users "Brian,Carol,David" the authors of the versions of file "/Shares/test (1)/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Brian |
| 3 | Alice |
When user "Brian" gets the number of versions of file "/test/textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "1"
And the content of version index "1" of file "/test/textfile0.txt" for user "Brian" should be "duplicate brian"
And as user "Brian" the authors of the versions of file "/test/textfile0.txt" should be:
| index | author |
| 1 | Brian |
When user "Carol" gets the number of versions of file "/test/textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "0"
Scenario: enable file versioning and check the history of changes from multiple users who have a matching file
Given user "David" has been created with default attributes
And user "Brian" has uploaded file with content "duplicate brian" to "/textfile0.txt"
And user "Brian" has uploaded file with content "overwrite brian" to "/textfile0.txt"
And user "Brian" has sent the following resource share invitation:
| resource | textfile0.txt |
| space | Personal |
| sharee | Carol |
| shareType | user |
| permissionsRole | File Editor |
And user "Carol" has a share "textfile0.txt" synced
And user "Brian" has sent the following resource share invitation:
| resource | textfile0.txt |
| space | Personal |
| sharee | David |
| shareType | user |
| permissionsRole | File Editor |
And user "David" has a share "textfile0.txt" synced
And user "Carol" has uploaded file with content "duplicate carol" to "/textfile0.txt"
And user "Carol" has sent the following resource share invitation:
| resource | textfile0.txt |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | File Editor |
And user "Brian" has a share "textfile0.txt" synced
And user "Alice" has uploaded file with content "uploaded content alice" to "/textfile0.txt"
And user "Alice" has sent the following resource share invitation:
| resource | textfile0.txt |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | File Editor |
And user "Brian" has a share "textfile0 (1).txt" synced
And user "Alice" has sent the following resource share invitation:
| resource | textfile0.txt |
| space | Personal |
| sharee | Carol |
| shareType | user |
| permissionsRole | File Editor |
And user "Carol" has a share "textfile0 (1).txt" synced
And user "Alice" has sent the following resource share invitation:
| resource | textfile0.txt |
| space | Personal |
| sharee | David |
| shareType | user |
| permissionsRole | File Editor |
And user "David" has a share "textfile0 (1).txt" synced
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/textfile0 (1).txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/textfile0 (1).txt"
And user "David" has uploaded file with content "uploaded content david" to "/Shares/textfile0 (1).txt"
When user "Alice" gets the number of versions of file "/textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "3"
And the content of version index "1" of file "/textfile0.txt" for user "Alice" should be "uploaded content carol"
And the content of version index "2" of file "/textfile0.txt" for user "Alice" should be "uploaded content brian"
And the content of version index "3" of file "/textfile0.txt" for user "Alice" should be "uploaded content alice"
And as users "Alice" the authors of the versions of file "/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Brian |
| 3 | Alice |
And as users "Brian,Carol,David" the authors of the versions of file "/Shares/textfile0 (1).txt" should be:
| index | author |
| 1 | Carol |
| 2 | Brian |
| 3 | Alice |
When user "Brian" gets the number of versions of file "/textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "1"
And the content of version index "1" of file "/textfile0.txt" for user "Brian" should be "duplicate brian"
And as user "Brian" the authors of the versions of file "/textfile0.txt" should be:
| index | author |
| 1 | Brian |
When user "Carol" gets the number of versions of file "/textfile0.txt"
Then the HTTP status code should be "207"
And the number of versions should be "0"
Scenario: enable file versioning and check the version author after restoring a version of a file inside a folder
Given user "Alice" has created folder "/test"
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | Editor |
And user "Brian" has a share "test" synced
And user "Alice" has sent the following resource share invitation:
| resource | test |
| space | Personal |
| sharee | Carol |
| shareType | user |
| permissionsRole | Editor |
And user "Carol" has a share "test" synced
And user "Alice" has uploaded file with content "uploaded content alice" to "/test/textfile0.txt"
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/test/textfile0.txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/test/textfile0.txt"
When user "Brian" restores version index "1" of file "/Shares/test/textfile0.txt" using the WebDAV API
Then the HTTP status code should be "204"
And as user "Alice" the authors of the versions of file "/test/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Alice |
And as user "Brian,Carol" the authors of the versions of file "/Shares/test/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Alice |
Scenario: enable file versioning and check the version author after restoring a version of a file
Given user "Alice" has uploaded file with content "uploaded content alice" to "/textfile0.txt"
And user "Alice" has sent the following resource share invitation:
| resource | textfile0.txt |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | File Editor |
And user "Brian" has a share "textfile0.txt" synced
And user "Alice" has sent the following resource share invitation:
| resource | textfile0.txt |
| space | Personal |
| sharee | Carol |
| shareType | user |
| permissionsRole | File Editor |
And user "Carol" has a share "textfile0.txt" synced
And user "Brian" has uploaded file with content "uploaded content brian" to "/Shares/textfile0.txt"
And user "Carol" has uploaded file with content "uploaded content carol" to "/Shares/textfile0.txt"
When user "Brian" restores version index "1" of file "/Shares/textfile0.txt" using the WebDAV API
Then the HTTP status code should be "204"
And as user "Alice" the authors of the versions of file "/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Alice |
And as user "Brian,Carol" the authors of the versions of file "/Shares/textfile0.txt" should be:
| index | author |
| 1 | Carol |
| 2 | Alice |