Capabilities related scenarios are added in expected failure
This commit is contained in:
6 files changed
+668
-131
No files matched your search
+1
-1
@@ -851,7 +851,7 @@ def wopiValidatorTests(ctx, storage, accounts_hash_difficulty = 4):
|
||||
|
||||
def coreApiTests(ctx, part_number = 1, number_of_parts = 1, storage = "ocis", accounts_hash_difficulty = 4):
|
||||
early_fail = config["apiTests"]["earlyFail"] if "earlyFail" in config["apiTests"] else False
|
||||
filterTags = "~@skipOnGraph&&~@skipOnOcis&&~@toImplementOnOCIS&&~comments-app-required&&~@federation-app-required&&~@notifications-app-required&&~systemtags-app-required&&~@local_storage&&~@skipOnOcis-%s-Storage&&~@caldav&&~@carddav" % ("OC" if storage == "owncloud" else "OCIS")
|
||||
filterTags = "~@skipOnGraph&&~@toImplementOnOCIS&&~comments-app-required&&~@federation-app-required&&~@notifications-app-required&&~systemtags-app-required&&~@local_storage&&~@skipOnOcis-%s-Storage&&~@caldav&&~@carddav" % ("OC" if storage == "owncloud" else "OCIS")
|
||||
expectedFailuresFile = "%s/tests/acceptance/expected-failures-API-on-%s-storage.md" % (dirs["base"], storage.upper())
|
||||
|
||||
return {
|
||||
|
||||
@@ -433,13 +433,6 @@ default:
|
||||
- WebDavPropertiesContext:
|
||||
- AppConfigurationContext:
|
||||
|
||||
coreApiTranslation:
|
||||
paths:
|
||||
- "%paths.base%/../features/coreApiTranslation"
|
||||
context: *common_ldap_suite_context
|
||||
contexts:
|
||||
- FeatureContext: *common_feature_context_params
|
||||
|
||||
extensions:
|
||||
rdx\behatvars\BehatVariablesExtension: ~
|
||||
|
||||
|
||||
@@ -178,12 +178,12 @@ File and sync features in a shared scenario
|
||||
- [coreApiShareManagementToShares/acceptShares.feature:230](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareManagementToShares/acceptShares.feature#L230)
|
||||
- [coreApiShareManagementToShares/acceptShares.feature:495](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareManagementToShares/acceptShares.feature#L495)
|
||||
- [coreApiShareManagementToShares/acceptShares.feature:560](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareManagementToShares/acceptShares.feature#L560)
|
||||
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:141](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L141)
|
||||
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:129](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L129)
|
||||
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:181](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L181)
|
||||
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:130](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L130)
|
||||
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:164](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L164)
|
||||
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:45](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L45)
|
||||
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:165](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L165)
|
||||
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:38](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L38)
|
||||
- [coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature:39](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares2/createShareReceivedInMultipleWays.feature#L39)
|
||||
|
||||
#### [sharing the shares folder to users exits with different status code than in oc10 backend](https://github.com/owncloud/ocis/issues/2215)
|
||||
|
||||
@@ -398,8 +398,8 @@ cannot share a folder with create permission
|
||||
|
||||
- [coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature:175](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature#L175)
|
||||
- [coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature:176](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature#L176)
|
||||
- [coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature:73](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature#L73)
|
||||
- [coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature:74](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature#L74)
|
||||
- [coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature:201](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature#L201)
|
||||
- [coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature:202](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature#L202)
|
||||
- [coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature:229](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature#L229)
|
||||
- [coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature:230](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature#L230)
|
||||
- [coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature:258](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareCreateSpecialToShares1/createShareExpirationDate.feature#L258)
|
||||
@@ -429,7 +429,7 @@ cannot share a folder with create permission
|
||||
|
||||
#### [Cannot move folder/file from one received share to another](https://github.com/owncloud/ocis/issues/2442)
|
||||
|
||||
- [coreApiShareUpdateToShares/updateShare.feature:201](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareUpdateToShares/updateShare.feature#L201)
|
||||
- [coreApiShareUpdateToShares/updateShare.feature:196](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareUpdateToShares/updateShare.feature#L196)
|
||||
- [coreApiShareUpdateToShares/updateShare.feature:160](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareUpdateToShares/updateShare.feature#L160)
|
||||
- [coreApiShareManagementToShares/mergeShare.feature:136](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareManagementToShares/mergeShare.feature#L136)
|
||||
|
||||
@@ -676,8 +676,8 @@ And other missing implementation of favorites
|
||||
|
||||
#### [Shares to deleted group listed in the response](https://github.com/owncloud/ocis/issues/2441)
|
||||
|
||||
- [coreApiShareManagementBasicToShares/createShareToSharesFolder.feature:534](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareManagementBasicToShares/createShareToSharesFolder.feature#L534)
|
||||
- [coreApiShareManagementBasicToShares/createShareToSharesFolder.feature:529](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareManagementBasicToShares/createShareToSharesFolder.feature#L529)
|
||||
- [coreApiShareManagementBasicToShares/createShareToSharesFolder.feature:530](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiShareManagementBasicToShares/createShareToSharesFolder.feature#L530)
|
||||
|
||||
#### [copying the file inside Shares folder returns 404](https://github.com/owncloud/ocis/issues/3874)
|
||||
|
||||
@@ -727,9 +727,9 @@ Not everything needs to be implemented for ocis. While the oc10 testsuite covers
|
||||
- [coreApiWebdavUpload2/uploadFileToExcludedDirectoryUsingOldChunking.feature:38](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavUpload2/uploadFileToExcludedDirectoryUsingOldChunking.feature#L38)
|
||||
- [coreApiWebdavUpload2/uploadFileToExcludedDirectoryUsingOldChunking.feature:39](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavUpload2/uploadFileToExcludedDirectoryUsingOldChunking.feature#L39)
|
||||
- [coreApiWebdavUpload2/uploadFileToExcludedDirectoryUsingOldChunking.feature:40](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavUpload2/uploadFileToExcludedDirectoryUsingOldChunking.feature#L40)
|
||||
- [coreApiWebdavMove2/moveFile.feature:287](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFile.feature#L287)
|
||||
- [coreApiWebdavMove2/moveFile.feature:288](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFile.feature#L288)
|
||||
- [coreApiWebdavMove2/moveFile.feature:293](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFile.feature#L293)
|
||||
- [coreApiWebdavMove2/moveFile.feature:176](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFile.feature#L176)
|
||||
- [coreApiWebdavMove2/moveFile.feature:177](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFile.feature#L177)
|
||||
- [coreApiWebdavMove2/moveFile.feature:182](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFile.feature#L182)
|
||||
|
||||
#### [cannot set blacklisted file names](https://github.com/owncloud/product/issues/260)
|
||||
|
||||
@@ -817,7 +817,7 @@ Not everything needs to be implemented for ocis. While the oc10 testsuite covers
|
||||
- [coreApiWebdavMove1/moveFolder.feature:27](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove1/moveFolder.feature#L27)
|
||||
- [coreApiWebdavMove1/moveFolder.feature:45](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove1/moveFolder.feature#L45)
|
||||
- [coreApiWebdavMove1/moveFolder.feature:63](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove1/moveFolder.feature#L63)
|
||||
- [coreApiWebdavMove2/moveFile.feature:224](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFile.feature#L224)
|
||||
- [coreApiWebdavMove2/moveFile.feature:138](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFile.feature#L138)
|
||||
- [coreApiWebdavMove2/moveFileToBlacklistedName.feature:25](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFileToBlacklistedName.feature#L25)
|
||||
- [coreApiWebdavMove2/moveFileToBlacklistedName.feature:41](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFileToBlacklistedName.feature#L41)
|
||||
- [coreApiWebdavMove2/moveFileToBlacklistedName.feature:80](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiWebdavMove2/moveFileToBlacklistedName.feature#L80)
|
||||
@@ -863,7 +863,7 @@ Not everything needs to be implemented for ocis. While the oc10 testsuite covers
|
||||
|
||||
#### [HTTP status code differ while deleting file of another user's trash bin](https://github.com/owncloud/ocis/issues/3544)
|
||||
|
||||
- [coreApiTrashbin/trashbinDelete.feature:104](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinDelete.feature#L104)
|
||||
- [coreApiTrashbin/trashbinDelete.feature:105](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinDelete.feature#L105)
|
||||
|
||||
#### [Problem accessing trashbin with personal space id](https://github.com/owncloud/ocis/issues/3639)
|
||||
|
||||
@@ -899,5 +899,9 @@ Not everything needs to be implemented for ocis. While the oc10 testsuite covers
|
||||
- [coreApiTrashbin/trashbinFilesFolders.feature:426](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L426)
|
||||
- [coreApiTrashbin/trashbinFilesFolders.feature:463](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiTrashbin/trashbinFilesFolders.feature#L463)
|
||||
|
||||
#### [Default capabilities for normal user and admin user not same as in oC-core](https://github.com/owncloud/ocis/issues/1285)
|
||||
- [coreApiCapabilities/capabilities.feature:8](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiCapabilities/capabilities.feature#L8)
|
||||
- [coreApiCapabilities/capabilities.feature:35](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiCapabilities/capabilities.feature#L35)
|
||||
- [coreApiCapabilities/capabilities.feature:44](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/coreApiCapabilities/capabilities.feature#L44)
|
||||
Note: always have an empty line at the end of this file.
|
||||
The bash script that processes this file requires that the last line has a newline on the end.
|
||||
@@ -1,32 +1,10 @@
|
||||
@api @files_sharing-app-required @issue-ocis-reva-41
|
||||
@api @files_sharing-app-required
|
||||
Feature: capabilities
|
||||
|
||||
Background:
|
||||
Given using OCS API version "1"
|
||||
|
||||
@smokeTest @skipOnOcis
|
||||
Scenario: getting new default capabilities in versions after 10.5.0 with admin user
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
Then the OCS status code should be "100"
|
||||
And the HTTP status code should be "200"
|
||||
And the capabilities should contain
|
||||
| capability | path_to_element | value |
|
||||
| files | favorites | 1 |
|
||||
| files | file_locking_support | 1 |
|
||||
| files | file_locking_enable_file_action | EMPTY |
|
||||
|
||||
@smokeTest @skipOnOcis
|
||||
Scenario: lock file action can be enabled
|
||||
Given parameter "enable_lock_file_action" of app "files" has been set to "yes"
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
Then the OCS status code should be "100"
|
||||
And the HTTP status code should be "200"
|
||||
And the capabilities should contain
|
||||
| capability | path_to_element | value |
|
||||
| files | file_locking_support | 1 |
|
||||
| files | file_locking_enable_file_action | 1 |
|
||||
|
||||
@smokeTest @skipOnOcis
|
||||
@smokeTest @issue-ocis-1285
|
||||
Scenario: getting default capabilities with admin user
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
Then the OCS status code should be "100"
|
||||
@@ -53,7 +31,7 @@ Feature: capabilities
|
||||
| capability | path_to_element | value |
|
||||
| files | versioning | 1 |
|
||||
|
||||
@skipOnOcis
|
||||
@issue-ocis-1285
|
||||
Scenario: getting default_permissions capability with admin user
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
Then the OCS status code should be "100"
|
||||
@@ -62,7 +40,7 @@ Feature: capabilities
|
||||
| capability | path_to_element | value |
|
||||
| files_sharing | default_permissions | 31 |
|
||||
|
||||
@skipOnOcis
|
||||
@issue-ocis-1285
|
||||
Scenario: .htaccess is reported as a blacklisted file by default
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
Then the OCS status code should be "100"
|
||||
@@ -71,55 +49,6 @@ Feature: capabilities
|
||||
| capability | path_to_element | value |
|
||||
| files | blacklisted_files@@@element[0] | .htaccess |
|
||||
|
||||
@skipOnOcis
|
||||
Scenario: multiple files can be reported as blacklisted
|
||||
Given the administrator has updated system config key "blacklisted_files" with value '["test.txt",".htaccess"]' and type "json"
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
Then the OCS status code should be "100"
|
||||
And the HTTP status code should be "200"
|
||||
And the capabilities should contain
|
||||
| capability | path_to_element | value |
|
||||
| files | blacklisted_files@@@element[0] | test.txt |
|
||||
| files | blacklisted_files@@@element[1] | .htaccess |
|
||||
|
||||
#feature added in #31824 released in 10.0.10
|
||||
@smokeTest @skipOnOcis
|
||||
Scenario: getting capabilities with admin user
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
Then the OCS status code should be "100"
|
||||
And the HTTP status code should be "200"
|
||||
And the capabilities should contain
|
||||
| capability | path_to_element | value |
|
||||
| files_sharing | can_share | 1 |
|
||||
|
||||
#feature added in #32414 released in 10.0.10
|
||||
@skipOnOcis
|
||||
Scenario: getting async capabilities when async operations are enabled
|
||||
Given the administrator has enabled async operations
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
Then the OCS status code should be "100"
|
||||
And the HTTP status code should be "200"
|
||||
And the capabilities should contain
|
||||
| capability | path_to_element | value |
|
||||
| async | | 1.0 |
|
||||
|
||||
|
||||
Scenario: getting async capabilities when async operations are disabled
|
||||
Given the administrator has disabled async operations
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
Then the capabilities should contain
|
||||
| capability | path_to_element | value |
|
||||
| async | | EMPTY |
|
||||
|
||||
@skipOnOcis
|
||||
Scenario: blacklisted_files_regex is reported in capabilities
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
Then the OCS status code should be "100"
|
||||
And the HTTP status code should be "200"
|
||||
And the capabilities should contain
|
||||
| capability | path_to_element | value |
|
||||
| files | blacklisted_files_regex | \.(part\|filepart)$ |
|
||||
|
||||
@smokeTest
|
||||
Scenario: getting default capabilities with admin user
|
||||
When the administrator retrieves the capabilities using the capabilities API
|
||||
|
||||
+647
@@ -28,6 +28,107 @@ Feature: a default expiration date can be specified for shares with users or gro
|
||||
| 2 | 200 | 200 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled but not enforced for users, user shares with expiration date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And user "Alice" has created folder "/FOLDER"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | /FOLDER |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDate | +15 days |
|
||||
When user "Brian" accepts share "/FOLDER" offered by user "Alice" using the sharing API
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | user |
|
||||
| file_target | /Shares/FOLDER |
|
||||
| uid_owner | %username% |
|
||||
| expiration | +15 days |
|
||||
| share_with | %username% |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +15 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date not enabled, user shares with expiration date set
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And user "Alice" has created folder "/FOLDER"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | /FOLDER |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDate | +15 days |
|
||||
When user "Brian" accepts share "/FOLDER" offered by user "Alice" using the sharing API
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | user |
|
||||
| file_target | /Shares/FOLDER |
|
||||
| uid_owner | %username% |
|
||||
| expiration | +15 days |
|
||||
| share_with | %username% |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +15 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled but not enforced for users, user shares with expiration date and then disables
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And user "Alice" has created folder "/FOLDER"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | /FOLDER |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDate | +15 days |
|
||||
And user "Brian" has accepted share "/FOLDER" offered by user "Alice"
|
||||
When the administrator sets parameter "shareapi_default_expire_date_user_share" of app "core" to "no"
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | user |
|
||||
| file_target | /Shares/FOLDER |
|
||||
| uid_owner | %username% |
|
||||
| expiration | +15 days |
|
||||
| share_with | %username% |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +15 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for users, user shares with expiration date and then disables
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And user "Alice" has created folder "/FOLDER"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | /FOLDER |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
And user "Brian" has accepted share "/FOLDER" offered by user "Alice"
|
||||
When the administrator sets parameter "shareapi_default_expire_date_user_share" of app "core" to "no"
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | user |
|
||||
| file_target | /Shares/FOLDER |
|
||||
| uid_owner | %username% |
|
||||
| share_with | %username% |
|
||||
| expiration | +7 days |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +7 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled but not enforced for groups, user shares without specifying expireDate
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_group_share" of app "core" has been set to "yes"
|
||||
@@ -48,6 +149,33 @@ Feature: a default expiration date can be specified for shares with users or gro
|
||||
| 2 | 200 | 200 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled but not enforced for groups, user shares with expiration date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And group "grp1" has been created
|
||||
And user "Brian" has been added to group "grp1"
|
||||
And user "Alice" has created folder "/FOLDER"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | /FOLDER |
|
||||
| shareType | group |
|
||||
| shareWith | grp1 |
|
||||
| permissions | read,share |
|
||||
| expireDate | +15 days |
|
||||
When user "Brian" accepts share "/FOLDER" offered by user "Alice" using the sharing API
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | group |
|
||||
| file_target | /Shares/FOLDER |
|
||||
| uid_owner | %username% |
|
||||
| expiration | +15 days |
|
||||
| share_with | grp1 |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +15 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date not enabled for groups, user shares with expiration date set
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And group "grp1" has been created
|
||||
@@ -74,6 +202,323 @@ Feature: a default expiration date can be specified for shares with users or gro
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled but not enforced for groups, user shares with expiration date and then disables
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And group "grp1" has been created
|
||||
And user "Brian" has been added to group "grp1"
|
||||
And user "Alice" has created folder "/FOLDER"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | /FOLDER |
|
||||
| shareType | group |
|
||||
| shareWith | grp1 |
|
||||
| permissions | read,share |
|
||||
| expireDate | +15 days |
|
||||
And user "Brian" has accepted share "/FOLDER" offered by user "Alice"
|
||||
When the administrator sets parameter "shareapi_default_expire_date_group_share" of app "core" to "no"
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | group |
|
||||
| file_target | /Shares/FOLDER |
|
||||
| uid_owner | %username% |
|
||||
| share_with | grp1 |
|
||||
| expiration | +15 days |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +15 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for groups, user shares with expiration date and then disables
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And group "grp1" has been created
|
||||
And user "Brian" has been added to group "grp1"
|
||||
And user "Alice" has created folder "/FOLDER"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | /FOLDER |
|
||||
| shareType | group |
|
||||
| shareWith | grp1 |
|
||||
| permissions | read,share |
|
||||
| expireDate | +3 days |
|
||||
And user "Brian" has accepted share "/FOLDER" offered by user "Alice"
|
||||
When the administrator sets parameter "shareapi_default_expire_date_group_share" of app "core" to "no"
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | group |
|
||||
| file_target | /Shares/FOLDER |
|
||||
| uid_owner | %username% |
|
||||
| share_with | grp1 |
|
||||
| expiration | +3 days |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +3 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for users, user shares without setting expiration date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has shared file "/textfile0.txt" with user "Brian"
|
||||
When user "Brian" accepts share "/textfile0.txt" offered by user "Alice" using the sharing API
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | user |
|
||||
| file_target | /Shares/textfile0.txt |
|
||||
| uid_owner | %username% |
|
||||
| share_with | %username% |
|
||||
| expiration | +7 days |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +7 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for users, user shares with expiration date more than the default
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
When user "Alice" creates a share using the sharing API with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDate | +10 days |
|
||||
Then the HTTP status code should be "<http_status_code>"
|
||||
And the OCS status code should be "404"
|
||||
And the OCS status message should be "Cannot set expiration date more than 7 days in the future"
|
||||
And the sharing API should report to user "Brian" that no shares are in the pending state
|
||||
And user "Brian" should not have any received shares
|
||||
Examples:
|
||||
| ocs_api_version | http_status_code |
|
||||
| 1 | 200 |
|
||||
| 2 | 404 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for users/max expire date is set, user shares without setting expiration date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_expire_after_n_days_user_share" of app "core" has been set to "30"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has shared file "/textfile0.txt" with user "Brian"
|
||||
When user "Brian" accepts share "/textfile0.txt" offered by user "Alice" using the sharing API
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | user |
|
||||
| file_target | /Shares/textfile0.txt |
|
||||
| uid_owner | %username% |
|
||||
| share_with | %username% |
|
||||
| expiration | +30 days |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +30 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for users/max expire date set, user shares with expiration date more than the max expire date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_expire_after_n_days_user_share" of app "core" has been set to "30"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
When user "Alice" creates a share using the sharing API with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDate | +40 days |
|
||||
Then the HTTP status code should be "<http_status_code>"
|
||||
And the OCS status code should be "404"
|
||||
And the OCS status message should be "Cannot set expiration date more than 30 days in the future"
|
||||
And the sharing API should report to user "Brian" that no shares are in the pending state
|
||||
And user "Brian" should not have any received shares
|
||||
Examples:
|
||||
| ocs_api_version | http_status_code |
|
||||
| 1 | 200 |
|
||||
| 2 | 404 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for users/max expire date is set, user shares and changes the max expire date greater than the previous one
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_expire_after_n_days_user_share" of app "core" has been set to "30"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has shared file "textfile0.txt" with user "Brian" with permissions "read,share"
|
||||
And user "Brian" has accepted share "/textfile0.txt" offered by user "Alice"
|
||||
When the administrator sets parameter "shareapi_expire_after_n_days_user_share" of app "core" to "40"
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| expiration | +30 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled for users/max expire date is set, user shares and changes max expire date less than the previous one
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_expire_after_n_days_user_share" of app "core" has been set to "30"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has shared file "textfile0.txt" with user "Brian" with permissions "read,share"
|
||||
And user "Brian" has accepted share "/textfile0.txt" offered by user "Alice"
|
||||
When the administrator sets parameter "shareapi_expire_after_n_days_user_share" of app "core" to "15"
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| expiration | +30 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for groups, user shares without setting expiration date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And group "grp1" has been created
|
||||
And user "Brian" has been added to group "grp1"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has shared file "textfile0.txt" with group "grp1"
|
||||
When user "Brian" accepts share "/textfile0.txt" offered by user "Alice" using the sharing API
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | group |
|
||||
| file_target | /Shares/textfile0.txt |
|
||||
| uid_owner | %username% |
|
||||
| share_with | grp1 |
|
||||
| expiration | +7 days |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +7 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for groups, user shares with expiration date more than the default
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And group "grp1" has been created
|
||||
And user "Brian" has been added to group "grp1"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
When user "Alice" creates a share using the sharing API with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | group |
|
||||
| shareWith | grp1 |
|
||||
| permissions | read,share |
|
||||
| expireDate | +10 days |
|
||||
Then the HTTP status code should be "<http_status_code>"
|
||||
And the OCS status code should be "404"
|
||||
And the OCS status message should be "Cannot set expiration date more than 7 days in the future"
|
||||
And the sharing API should report to user "Brian" that no shares are in the pending state
|
||||
And user "Brian" should not have any received shares
|
||||
Examples:
|
||||
| ocs_api_version | http_status_code |
|
||||
| 1 | 200 |
|
||||
| 2 | 404 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for groups/max expire date is set, user shares without setting expiration date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_expire_after_n_days_group_share" of app "core" has been set to "30"
|
||||
And group "grp1" has been created
|
||||
And user "Brian" has been added to group "grp1"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has shared file "textfile0.txt" with group "grp1"
|
||||
When user "Brian" accepts share "/textfile0.txt" offered by user "Alice" using the sharing API
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| share_type | group |
|
||||
| file_target | /Shares/textfile0.txt |
|
||||
| uid_owner | %username% |
|
||||
| share_with | grp1 |
|
||||
| expiration | +30 days |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +30 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled and enforced for groups/max expire date set, user shares with expiration date more than the max expire date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_expire_after_n_days_group_share" of app "core" has been set to "30"
|
||||
And group "grp1" has been created
|
||||
And user "Brian" has been added to group "grp1"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
When user "Alice" creates a share using the sharing API with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | group |
|
||||
| shareWith | grp1 |
|
||||
| permissions | read,share |
|
||||
| expireDate | +40 days |
|
||||
Then the HTTP status code should be "<http_status_code>"
|
||||
And the OCS status code should be "404"
|
||||
And the OCS status message should be "Cannot set expiration date more than 30 days in the future"
|
||||
And the sharing API should report to user "Brian" that no shares are in the pending state
|
||||
And user "Brian" should not have any received shares
|
||||
Examples:
|
||||
| ocs_api_version | http_status_code |
|
||||
| 1 | 200 |
|
||||
| 2 | 404 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled for groups/max expire date is set, user shares and changes the max expire date greater than the previous one
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_expire_after_n_days_group_share" of app "core" has been set to "30"
|
||||
And group "grp1" has been created
|
||||
And user "Brian" has been added to group "grp1"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has shared file "textfile0.txt" with group "grp1" with permissions "read,share"
|
||||
And user "Brian" has accepted share "/textfile0.txt" offered by user "Alice"
|
||||
When the administrator sets parameter "shareapi_expire_after_n_days_group_share" of app "core" to "40"
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| expiration | +30 days |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +30 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enabled for groups/max expire date is set, user shares and changes max expire date less than the previous one
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_group_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_expire_after_n_days_group_share" of app "core" has been set to "30"
|
||||
And group "grp1" has been created
|
||||
And user "Brian" has been added to group "grp1"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has shared file "textfile0.txt" with group "grp1" with permissions "read,share"
|
||||
And user "Brian" has accepted share "/textfile0.txt" offered by user "Alice"
|
||||
When the administrator sets parameter "shareapi_expire_after_n_days_group_share" of app "core" to "15"
|
||||
Then the info about the last share by user "Alice" with user "Brian" should include
|
||||
| expiration | +30 days |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | +30 days |
|
||||
Examples:
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enforced for users, user shares to a group without setting an expiration date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
@@ -108,3 +553,205 @@ Feature: a default expiration date can be specified for shares with users or gro
|
||||
| ocs_api_version |
|
||||
| 1 |
|
||||
| 2 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enforced for users, user shares with invalid expiration date set
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
When user "Alice" creates a share using the sharing API with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDateAsString | INVALID-DATE |
|
||||
Then the HTTP status code should be "<http_status_code>"
|
||||
And the OCS status code should be "<ocs_status_code>"
|
||||
And the OCS status message should be "Invalid date, date format must be YYYY-MM-DD"
|
||||
And the sharing API should report to user "Brian" that no shares are in the pending state
|
||||
And user "Brian" should not have any received shares
|
||||
Examples:
|
||||
| ocs_api_version | ocs_status_code | http_status_code |
|
||||
| 1 | 404 | 200 |
|
||||
| 2 | 404 | 404 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enforced for users, user shares with different time format
|
||||
Given using OCS API version "2"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDateAsString | <date> |
|
||||
When user "Brian" accepts share "/textfile0.txt" offered by user "Alice" using the sharing API
|
||||
Then the HTTP status code should be "200"
|
||||
And the OCS status code should be "200"
|
||||
And the fields of the last response to user "Alice" should include
|
||||
| expiration | 2050-12-11 |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | 2050-12-11 |
|
||||
Examples:
|
||||
| date |
|
||||
| 2050-12-11 |
|
||||
| 11-12-2050 |
|
||||
| 12/11/2050 |
|
||||
| 11.12.2050 |
|
||||
| 11.12.2050 12:30:40 |
|
||||
|
||||
|
||||
Scenario Outline: user shares with humanized expiration date format
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "<default>"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "<enforce>"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDateAsString | <expiration_date> |
|
||||
When user "Brian" accepts share "/textfile0.txt" offered by user "Alice" using the sharing API
|
||||
Then the fields of the last response to user "Alice" should include
|
||||
| expiration | <expiration_date> |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | <expiration_date> |
|
||||
Examples:
|
||||
| ocs_api_version | expiration_date | default | enforce |
|
||||
| 1 | today | yes | yes |
|
||||
| 2 | today | yes | yes |
|
||||
| 1 | tomorrow | yes | yes |
|
||||
| 2 | tomorrow | yes | yes |
|
||||
| 1 | today | yes | no |
|
||||
| 2 | today | yes | no |
|
||||
| 1 | tomorrow | yes | no |
|
||||
| 2 | tomorrow | yes | no |
|
||||
| 1 | today | no | no |
|
||||
| 2 | today | no | no |
|
||||
| 1 | tomorrow | no | no |
|
||||
| 2 | tomorrow | no | no |
|
||||
|
||||
|
||||
Scenario Outline: user shares with humanized expiration date format in past
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "<default>"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "<enforce>"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
When user "Alice" creates a share using the sharing API with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDateAsString | yesterday |
|
||||
Then the HTTP status code should be "<http_status_code>"
|
||||
And the OCS status code should be "<ocs_status_code>"
|
||||
And the OCS status message should be "Expiration date is in the past"
|
||||
And the sharing API should report to user "Brian" that no shares are in the pending state
|
||||
And user "Brian" should not have any received shares
|
||||
Examples:
|
||||
| ocs_api_version | ocs_status_code | http_status_code | default | enforce |
|
||||
| 1 | 404 | 200 | yes | yes |
|
||||
| 2 | 404 | 404 | yes | yes |
|
||||
| 1 | 404 | 200 | yes | no |
|
||||
| 2 | 404 | 404 | yes | no |
|
||||
| 1 | 404 | 200 | no | no |
|
||||
| 2 | 404 | 404 | no | no |
|
||||
|
||||
|
||||
Scenario Outline: user shares with invalid humanized expiration date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "<default>"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "<enforce>"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
When user "Alice" creates a share using the sharing API with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDateAsString | 123 |
|
||||
Then the HTTP status code should be "<http_status_code>"
|
||||
And the OCS status code should be "<ocs_status_code>"
|
||||
And the OCS status message should be "Invalid date, date format must be YYYY-MM-DD"
|
||||
And the sharing API should report to user "Brian" that no shares are in the pending state
|
||||
And user "Brian" should not have any received shares
|
||||
Examples:
|
||||
| ocs_api_version | ocs_status_code | http_status_code | default | enforce |
|
||||
| 1 | 404 | 200 | yes | yes |
|
||||
| 2 | 404 | 404 | yes | yes |
|
||||
| 1 | 404 | 200 | yes | no |
|
||||
| 2 | 404 | 404 | yes | no |
|
||||
| 1 | 404 | 200 | no | no |
|
||||
| 2 | 404 | 404 | no | no |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enforced for users, user shares with past expiration date set
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
When user "Alice" creates a share using the sharing API with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
| expireDateAsString | -10 days |
|
||||
Then the HTTP status code should be "<http_status_code>"
|
||||
And the OCS status code should be "<ocs_status_code>"
|
||||
And the OCS status message should be "Expiration date is in the past"
|
||||
And the sharing API should report to user "Brian" that no shares are in the pending state
|
||||
And user "Brian" should not have any received shares
|
||||
Examples:
|
||||
| ocs_api_version | ocs_status_code | http_status_code |
|
||||
| 1 | 404 | 200 |
|
||||
| 2 | 404 | 404 |
|
||||
|
||||
@issue-36569
|
||||
Scenario Outline: sharing with default expiration date enforced for users, max expire date is 0, user shares without specifying expiration date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_expire_after_n_days_user_share" of app "core" has been set to "0"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
When user "Brian" accepts share "/textfile0.txt" offered by user "Alice" using the sharing API
|
||||
Then the HTTP status code should be "200"
|
||||
And the OCS status code should be "<ocs_status_code>"
|
||||
And the fields of the last response to user "Alice" should include
|
||||
| expiration | today |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | today |
|
||||
Examples:
|
||||
| ocs_api_version | ocs_status_code |
|
||||
| 1 | 100 |
|
||||
| 2 | 200 |
|
||||
|
||||
|
||||
Scenario Outline: sharing with default expiration date enforced for users, max expire date is 1, user shares without specifying expiration date
|
||||
Given using OCS API version "<ocs_api_version>"
|
||||
And parameter "shareapi_default_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_enforce_expire_date_user_share" of app "core" has been set to "yes"
|
||||
And parameter "shareapi_expire_after_n_days_user_share" of app "core" has been set to "1"
|
||||
And user "Alice" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Alice" has created a share with settings
|
||||
| path | textfile0.txt |
|
||||
| shareType | user |
|
||||
| shareWith | Brian |
|
||||
| permissions | read,share |
|
||||
When user "Brian" accepts share "/textfile0.txt" offered by user "Alice" using the sharing API
|
||||
Then the HTTP status code should be "200"
|
||||
And the OCS status code should be "<ocs_status_code>"
|
||||
And the fields of the last response to user "Alice" should include
|
||||
| expiration | tomorrow |
|
||||
And the response when user "Brian" gets the info of the last share should include
|
||||
| expiration | tomorrow |
|
||||
Examples:
|
||||
| ocs_api_version | ocs_status_code |
|
||||
| 1 | 100 |
|
||||
| 2 | 200 |
|
||||
@@ -1,36 +0,0 @@
|
||||
@api @skipOnLDAP @skipOnOcis
|
||||
Feature: translate messages in api response to preferred language
|
||||
As a user
|
||||
I want response messages to be translated in preferred language
|
||||
So that I can see and understand the response messages in my language
|
||||
|
||||
Scenario Outline: user tries to get non existing share and uses some preferred language
|
||||
Given these users have been created with default attributes and without skeleton files:
|
||||
| username |
|
||||
| Alice |
|
||||
| Brian |
|
||||
| Carol |
|
||||
And using <dav_version> DAV path
|
||||
And user "Brian" has uploaded file "filesForUpload/textfile.txt" to "/textfile0.txt"
|
||||
And user "Brian" has shared file "textfile0.txt" with user "Carol"
|
||||
When user "Alice" gets the info of the last share in language "<language>" using the sharing API
|
||||
Then the OCS status code should be "404"
|
||||
And the OCS status message should be "Wrong share ID, share doesn't exist" in language "<language>"
|
||||
Examples:
|
||||
| dav_version | language |
|
||||
| old | de-DE |
|
||||
| old | es-ES |
|
||||
| old | zh-CN |
|
||||
| old | fr-FR |
|
||||
| new | de-DE |
|
||||
| new | es-ES |
|
||||
| new | zh-CN |
|
||||
| new | fr-FR |
|
||||
|
||||
@skipOnOcV10 @personalSpace
|
||||
Examples:
|
||||
| dav_version | language |
|
||||
| spaces | de-DE |
|
||||
| spaces | es-ES |
|
||||
| spaces | zh-CN |
|
||||
| spaces | fr-FR |
|
||||
Reference in new issue
Block a user