mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-12-05 14:39:23 -05:00
* tests: remove unused tags from the acceptance tests Remove the tags that neither the CI of opencloud nor the one of reva filters on, and that no hook uses: @smokeTest, @skipOnStorage:ceph, @skipOnStorage:scality, @skipOnOpencloud-decomposeds3-Storage (the CI only runs posix and decomposed), @sqliteDB, @notification and @skip-local-run. A tag line left empty becomes an empty line, so that the line numbers of the scenarios, which the expected failures of opencloud and reva refer to, stay the same. Also fix the typo @@skipOnReva, and write the issue tags the same way: @issues-<n> becomes @issue-<n>, @web-issue-<n> becomes @issue-web-<n>. Assisted-by: Claude Code:claude-opus-5-5 * tests: run the search properties scenarios as expected failures The two scenarios that check the properties of search results were skipped, since the search REPORT returns an empty d:getetag (#3501) and the step retried the whole check for 20 seconds, which made them too slow as expected failures. - retry the search only until the entry is indexed, then check its properties once: once found, the entry is complete, so a wrong value fails right away - check what the search returns: d:getcontentlength for files, the real size of 12 bytes, a file id of the form <uuid>$<uuid>!<uuid>, anchored patterns, and no oc:owner-id and oc:owner-display-name, which the search response never contains - list them as expected failures of #3501 instead of skipping them Without the d:getetag check, both scenarios pass. Assisted-by: Claude Code:claude-opus-5-5 * lint fix
149 lines
11 KiB
Gherkin
149 lines
11 KiB
Gherkin
@skipOnReva @issue-1328 @issue-1289
|
|
Feature: sharing
|
|
|
|
Background:
|
|
Given using OCS API version "1"
|
|
And these users have been created with default attributes:
|
|
| username |
|
|
| Alice |
|
|
| Brian |
|
|
And group "grp1" has been created
|
|
And user "Brian" has been added to group "grp1"
|
|
And user "Brian" has disabled auto-accepting
|
|
|
|
|
|
Scenario: merging shares for recipient when shared from outside with group and member
|
|
Given user "Alice" has created folder "/merge-test-outside"
|
|
When user "Alice" shares folder "/merge-test-outside" with group "grp1" using the sharing API
|
|
And user "Alice" shares folder "/merge-test-outside" with user "Brian" using the sharing API
|
|
And user "Brian" accepts share "/merge-test-outside" offered by user "Alice" using the sharing API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on all endpoints should be "200"
|
|
And as "Brian" folder "/Shares/merge-test-outside" should exist
|
|
And as "Brian" folder "/Shares/merge-test-outside (2)" should not exist
|
|
|
|
|
|
Scenario: merging shares for recipient when shared from outside with group and member with different permissions
|
|
Given user "Alice" has created folder "/merge-test-outside-perms"
|
|
When user "Alice" shares folder "/merge-test-outside-perms" with group "grp1" with permissions "read" using the sharing API
|
|
And user "Alice" shares folder "/merge-test-outside-perms" with user "Brian" with permissions "all" using the sharing API
|
|
And user "Brian" accepts share "/merge-test-outside-perms" offered by user "Alice" using the sharing API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on all endpoints should be "200"
|
|
And as user "Brian" folder "/Shares/merge-test-outside-perms" should contain a property "oc:permissions" with value "SDNVCK"
|
|
And as "Brian" folder "/Shares/merge-test-outside-perms (2)" should not exist
|
|
|
|
|
|
Scenario: merging shares for recipient when shared from outside with two groups
|
|
Given group "grp2" has been created
|
|
And user "Brian" has been added to group "grp2"
|
|
And user "Alice" has created folder "/merge-test-outside-twogroups"
|
|
When user "Alice" shares folder "/merge-test-outside-twogroups" with group "grp1" using the sharing API
|
|
And user "Alice" shares folder "/merge-test-outside-twogroups" with group "grp2" using the sharing API
|
|
And user "Brian" accepts share "/merge-test-outside-twogroups" offered by user "Alice" using the sharing API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on all endpoints should be "200"
|
|
And as "Brian" folder "/Shares/merge-test-outside-twogroups" should exist
|
|
And as "Brian" folder "/Shares/merge-test-outside-twogroups (2)" should not exist
|
|
|
|
|
|
Scenario: merging shares for recipient when shared from outside with two groups with different permissions
|
|
Given group "grp2" has been created
|
|
And user "Brian" has been added to group "grp2"
|
|
And user "Alice" has created folder "/merge-test-outside-twogroups-perms"
|
|
When user "Alice" shares folder "/merge-test-outside-twogroups-perms" with group "grp1" with permissions "read" using the sharing API
|
|
And user "Alice" shares folder "/merge-test-outside-twogroups-perms" with group "grp2" with permissions "all" using the sharing API
|
|
And user "Brian" accepts share "/merge-test-outside-twogroups-perms" offered by user "Alice" using the sharing API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on all endpoints should be "200"
|
|
And as user "Brian" folder "/Shares/merge-test-outside-twogroups-perms" should contain a property "oc:permissions" with value "SDNVCK"
|
|
And as "Brian" folder "/Shares/merge-test-outside-twogroups-perms (2)" should not exist
|
|
|
|
|
|
Scenario: merging shares for recipient when shared from outside with two groups and member
|
|
Given group "grp2" has been created
|
|
And user "Brian" has been added to group "grp2"
|
|
And user "Alice" has created folder "/merge-test-outside-twogroups-member-perms"
|
|
When user "Alice" shares folder "/merge-test-outside-twogroups-member-perms" with group "grp1" with permissions "read" using the sharing API
|
|
And user "Alice" shares folder "/merge-test-outside-twogroups-member-perms" with group "grp2" with permissions "all" using the sharing API
|
|
And user "Alice" shares folder "/merge-test-outside-twogroups-member-perms" with user "Brian" with permissions "read" using the sharing API
|
|
And user "Brian" accepts share "/merge-test-outside-twogroups-member-perms" offered by user "Alice" using the sharing API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on all endpoints should be "200"
|
|
And as user "Brian" folder "/Shares/merge-test-outside-twogroups-member-perms" should contain a property "oc:permissions" with value "SDNVCK"
|
|
And as "Brian" folder "/Shares/merge-test-outside-twogroups-member-perms (2)" should not exist
|
|
|
|
|
|
Scenario: merging shares for recipient when shared from inside with group
|
|
Given user "Brian" has created folder "/merge-test-inside-group"
|
|
When user "Brian" shares folder "/merge-test-inside-group" with group "grp1" using the sharing API
|
|
Then the OCS status code should be "100"
|
|
And the HTTP status code should be "200"
|
|
And as "Brian" folder "/merge-test-inside-group" should exist
|
|
And as "Brian" folder "/Shares/merge-test-inside-group" should not exist
|
|
|
|
|
|
Scenario: merging shares for recipient when shared from inside with two groups
|
|
Given group "grp2" has been created
|
|
And user "Brian" has been added to group "grp2"
|
|
And user "Brian" has created folder "/merge-test-inside-twogroups"
|
|
When user "Brian" shares folder "/merge-test-inside-twogroups" with group "grp1" using the sharing API
|
|
And user "Brian" shares folder "/merge-test-inside-twogroups" with group "grp2" using the sharing API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on all endpoints should be "200"
|
|
And as "Brian" folder "/merge-test-inside-twogroups" should exist
|
|
And as "Brian" folder "/Shares/merge-test-inside-twogroups" should not exist
|
|
And as "Brian" folder "/Shares/merge-test-inside-twogroups (2)" should not exist
|
|
|
|
|
|
Scenario: merging shares for recipient when shared from inside with group with less permissions
|
|
Given group "grp2" has been created
|
|
And user "Brian" has been added to group "grp2"
|
|
And user "Brian" has created folder "/merge-test-inside-twogroups-perms"
|
|
When user "Brian" shares folder "/merge-test-inside-twogroups-perms" with group "grp1" using the sharing API
|
|
And user "Brian" shares folder "/merge-test-inside-twogroups-perms" with group "grp2" using the sharing API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on all endpoints should be "200"
|
|
And as user "Brian" folder "/merge-test-inside-twogroups-perms" should contain a property "oc:permissions" with value "RDNVCKZP" or with value "RMDNVCKZP"
|
|
And as "Brian" folder "/Shares/merge-test-inside-twogroups-perms" should not exist
|
|
And as "Brian" folder "/Shares/merge-test-inside-twogroups-perms (2)" should not exist
|
|
|
|
|
|
Scenario: merging shares for recipient when shared from outside with group then user and recipient renames in between
|
|
And user "Alice" has created folder "/merge-test-outside-groups-renamebeforesecondshare"
|
|
# Section 1: Brian receives and accepts the group share from Alice and moves and renames it out of the "Shares" folder
|
|
When user "Alice" shares folder "/merge-test-outside-groups-renamebeforesecondshare" with group "grp1" using the sharing API
|
|
And user "Brian" accepts share "/merge-test-outside-groups-renamebeforesecondshare" offered by user "Alice" using the sharing API
|
|
And user "Brian" moves folder "/Shares/merge-test-outside-groups-renamebeforesecondshare" to "/merge-test-outside-groups-renamebeforesecondshare-renamed" using the WebDAV API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on each endpoint should be "200, 200, 502" respectively
|
|
And as "Brian" folder "/Shares/merge-test-outside-groups-renamebeforesecondshare" should exist
|
|
But as "Brian" folder "/merge-test-outside-groups-renamebeforesecondshare-renamed" should not exist
|
|
# Section 2: Brian receives and accepts the user share from Alice. Brian now has 2 shares of the same folder owned by Alice
|
|
# The server "merges" the 2 shares and presents them to Brian as a single folder inside the "Shares" folder
|
|
When user "Alice" shares folder "/merge-test-outside-groups-renamebeforesecondshare" with user "Brian" using the sharing API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on all endpoints should be "200"
|
|
And as "Brian" folder "/Shares/merge-test-outside-groups-renamebeforesecondshare" should exist
|
|
But as "Brian" folder "/merge-test-outside-groups-renamebeforesecondshare-renamed" should not exist
|
|
|
|
|
|
Scenario: merging shares for recipient when shared from outside with user then group and recipient renames in between
|
|
And user "Alice" has created folder "/merge-test-outside-groups-renamebeforesecondshare"
|
|
# Section 1: Brian receives and accepts the user share from Alice and moves and renames it out of the "Shares" folder
|
|
When user "Alice" shares folder "/merge-test-outside-groups-renamebeforesecondshare" with user "Brian" using the sharing API
|
|
And user "Brian" accepts share "/merge-test-outside-groups-renamebeforesecondshare" offered by user "Alice" using the sharing API
|
|
And user "Brian" moves folder "/Shares/merge-test-outside-groups-renamebeforesecondshare" to "/merge-test-outside-groups-renamebeforesecondshare-renamed" using the WebDAV API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on each endpoint should be "200, 200, 502" respectively
|
|
And as "Brian" folder "/Shares/merge-test-outside-groups-renamebeforesecondshare" should exist
|
|
But as "Brian" folder "/merge-test-outside-groups-renamebeforesecondshare-renamed" should not exist
|
|
# Section 2: Brian receives and accepts the group share from Alice. Brian now has 2 shares of the same folder owned by Alice
|
|
# The server "merges" the 2 shares and presents them to Brian as a single folder inside the "Shares" folder
|
|
When user "Alice" shares folder "/merge-test-outside-groups-renamebeforesecondshare" with group "grp1" using the sharing API
|
|
And user "Brian" accepts share "/merge-test-outside-groups-renamebeforesecondshare" offered by user "Alice" using the sharing API
|
|
Then the OCS status code of responses on all endpoints should be "100"
|
|
And the HTTP status code of responses on all endpoints should be "200"
|
|
And as "Brian" folder "/Shares/merge-test-outside-groups-renamebeforesecondshare" should exist
|
|
But as "Brian" folder "/merge-test-outside-groups-renamebeforesecondshare-renamed" should not exist
|