Skip to content

Commit

Permalink
Merge pull request #9217 from owncloud/use-sharingNG-in-given-steps-c…
Browse files Browse the repository at this point in the history
…oreApi

[full-ci] [tests-only] Use sharing-ng in given steps for sharing
  • Loading branch information
grgprarup authored May 21, 2024
2 parents 200a383 + 14fc824 commit 7efd92d
Show file tree
Hide file tree
Showing 5 changed files with 178 additions and 108 deletions.
2 changes: 2 additions & 0 deletions tests/acceptance/config/behat-core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ default:
- FilesVersionsContext:
- TrashbinContext:
- CapabilitiesContext:
- SharingNgContext:

coreApiAuth:
paths:
Expand Down Expand Up @@ -72,6 +73,7 @@ default:
- TrashbinContext:
- WebDavPropertiesContext:
- SettingsContext:
- SharingNgContext:

coreApiSharees:
paths:
Expand Down
24 changes: 12 additions & 12 deletions tests/acceptance/expected-failures-API-on-OCIS-storage.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ Synchronization features like etag propagation, setting mtime and locking files

#### [Uploading an old method chunked file with checksum should fail using new DAV path](https://github.com/owncloud/ocis/issues/2323)

- [coreApiMain/checksums.feature:258](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiMain/checksums.feature#L258)
- [coreApiMain/checksums.feature:263](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiMain/checksums.feature#L263)
- [coreApiMain/checksums.feature:268](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiMain/checksums.feature#L268)
- [coreApiMain/checksums.feature:273](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiMain/checksums.feature#L273)

### Share

Expand All @@ -64,12 +64,12 @@ File and sync features in a shared scenario
- [coreApiShareManagementToShares/acceptShares.feature:334](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareManagementToShares/acceptShares.feature#L334)
- [coreApiShareManagementToShares/acceptShares.feature:565](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareManagementToShares/acceptShares.feature#L565)
- [coreApiShareManagementToShares/acceptShares.feature:631](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareManagementToShares/acceptShares.feature#L631)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:39](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L39)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:40](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L40)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:126](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L126)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:127](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L127)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:159](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L159)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:160](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L160)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:44](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L44)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:45](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L45)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:141](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L141)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:142](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L142)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:174](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L174)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:175](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L175)

#### [file_target of an auto-renamed file is not correct directly after sharing](https://github.com/owncloud/core/issues/32322)

Expand Down Expand Up @@ -126,10 +126,10 @@ cannot share a folder with create permission

#### [Sharing folder and sub-folder with same user but different permission,the permission of sub-folder is not obeyed ](https://github.com/owncloud/ocis/issues/2440)

- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:213](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L213)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:239](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L239)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:292](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L292)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:318](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L318)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:232](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L232)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:260](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L260)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:317](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L317)
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:345](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L345)

#### [Empty OCS response for a share create request using a disabled user](https://github.com/owncloud/ocis/issues/2212)

Expand Down
14 changes: 12 additions & 2 deletions tests/acceptance/features/coreApiMain/checksums.feature
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,12 @@ Feature: checksums
Given using new DAV path
And user "Brian" has been created with default attributes and without skeleton files
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/myChecksumFile.txt" with checksum "MD5:d70b40f177b14b470d1756a3c12b963a"
And user "Alice" has shared file "/myChecksumFile.txt" with user "Brian"
And user "Alice" has sent the following resource share invitation:
| resource | myChecksumFile.txt |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | File Editor |
When user "Brian" requests the checksum of "/Shares/myChecksumFile.txt" via propfind
Then the HTTP status code should be "207"
And the webdav checksum should match "SHA1:3ee962b839762adb0ad8ba6023a4690be478de6f MD5:d70b40f177b14b470d1756a3c12b963a ADLER32:8ae90960"
Expand All @@ -189,7 +194,12 @@ Feature: checksums
Given using new DAV path
And user "Brian" has been created with default attributes and without skeleton files
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/myChecksumFile.txt" with checksum "MD5:d70b40f177b14b470d1756a3c12b963a"
And user "Alice" has shared file "/myChecksumFile.txt" with user "Brian"
And user "Alice" has sent the following resource share invitation:
| resource | myChecksumFile.txt |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | File Editor |
When user "Brian" uploads file with checksum "SHA1:ce5582148c6f0c1282335b87df5ed4be4b781399" and content "Some Text" to "/Shares/myChecksumFile.txt" using the WebDAV API
Then the HTTP status code should be "204"
And as user "Alice" the webdav checksum of "/myChecksumFile.txt" via propfind should match "SHA1:ce5582148c6f0c1282335b87df5ed4be4b781399 MD5:56e57920c3c8c727bfe7a5288cdf61c4 ADLER32:1048035a"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,12 @@ Feature: sharing works when a username and group name are the same
And group "Brian" has been created
And user "Carol" has been added to group "Brian"
And user "Alice" has uploaded file with content "Random data" to "/randomfile.txt"
And user "Alice" has shared file "randomfile.txt" with group "Brian"
And user "Alice" has sent the following resource share invitation:
| resource | randomfile.txt |
| space | Personal |
| sharee | Brian |
| shareType | group |
| permissionsRole | File Editor |
When user "Alice" shares file "randomfile.txt" with user "Brian" using the sharing API
Then the HTTP status code should be "200"
And the OCS status code should be "100"
Expand All @@ -36,7 +41,12 @@ Feature: sharing works when a username and group name are the same
And group "Brian" has been created
And user "Carol" has been added to group "Brian"
And user "Alice" has uploaded file with content "Random data" to "/randomfile.txt"
And user "Alice" has shared file "randomfile.txt" with user "Brian"
And user "Alice" has sent the following resource share invitation:
| resource | randomfile.txt |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | File Editor |
When user "Alice" shares file "randomfile.txt" with group "Brian" using the sharing API
Then the HTTP status code should be "200"
And the OCS status code should be "100"
Expand All @@ -56,7 +66,12 @@ Feature: sharing works when a username and group name are the same
And group "brian" has been created
And user "Carol" has been added to group "brian"
And user "Alice" has uploaded file with content "Random data" to "/randomfile.txt"
And user "Alice" has shared file "randomfile.txt" with group "brian"
And user "Alice" has sent the following resource share invitation:
| resource | randomfile.txt |
| space | Personal |
| sharee | brian |
| shareType | group |
| permissionsRole | File Editor |
When user "Alice" shares file "randomfile.txt" with user "Brian" using the sharing API
Then the HTTP status code should be "200"
And the OCS status code should be "100"
Expand All @@ -76,7 +91,12 @@ Feature: sharing works when a username and group name are the same
And group "brian" has been created
And user "Carol" has been added to group "brian"
And user "Alice" has uploaded file with content "Random data" to "/randomfile.txt"
And user "Alice" has shared file "randomfile.txt" with user "Brian"
And user "Alice" has sent the following resource share invitation:
| resource | randomfile.txt |
| space | Personal |
| sharee | Brian |
| shareType | user |
| permissionsRole | File Editor |
When user "Alice" shares file "randomfile.txt" with group "brian" using the sharing API
Then the HTTP status code should be "200"
And the OCS status code should be "100"
Expand Down
Loading

0 comments on commit 7efd92d

Please sign in to comment.