mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-01-20 12:00:48 -05:00
Merge pull request #9509 from owncloud/test/split-share-link-tests
[tests-only][full-ci] split SharingNG link share test suite
This commit is contained in:
@@ -232,49 +232,49 @@ The expected failures in this file are from features in the owncloud/ocis repo.
|
||||
|
||||
### [blocksDownload link type is not implemented yet (sharing-ng)](https://github.com/owncloud/ocis/issues/7879)
|
||||
|
||||
- [apiSharingNgLinkShare/linkShare.feature:72](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L72)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:202](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L202)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:340](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L340)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:409](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L409)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:475](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L475)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:541](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L541)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:543](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L543)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:544](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L544)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:545](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L545)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:611](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L611)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:959](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L959)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1105](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1105)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1161](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1161)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1162](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1162)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1163](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1163)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1268](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1268)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1334](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1334)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1478](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1478)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1547](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1547)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1597](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1597)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1598](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1598)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1599](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1599)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1838](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1838)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:1978](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L1978)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2032](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2032)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2033](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2033)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2034](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2034)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2102](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2102)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2169](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2169)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2240](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2240)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2421](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2421)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2680](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2680)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2734](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2734)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2735](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2735)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2736](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2736)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2804](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2804)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:2890](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L2890)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:3258](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L3258)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:3380](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L3380)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:3507](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L3507)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:3634](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L3634)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:3762](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L3762)
|
||||
- [apiSharingNgLinkShare/linkShare.feature:4030](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/linkShare.feature#L4030)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:72](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L72)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:202](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L202)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:340](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L340)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:409](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L409)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:475](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L475)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:616](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L616)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:762](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L762)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:818](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L818)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:819](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L819)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:820](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L820)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:890](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L890)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:956](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L956)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1100](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1100)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1169](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1169)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1219](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1219)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1220](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1220)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1221](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1221)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1460](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1460)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1600](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1600)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1654](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1654)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1655](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1655)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1656](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1656)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1724](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1724)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1791](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1791)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1862](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1862)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:1980](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L1980)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:2239](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L2239)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:2293](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L2293)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:2294](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L2294)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:2295](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L2295)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:2363](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L2363)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:2429](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L2429)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:2551](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L2551)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:2678](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L2678)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:2805](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L2805)
|
||||
- [apiSharingNgLinkShare/createLinkShare.feature:2933](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/createLinkShare.feature#L2933)
|
||||
- [apiSharingNgLinkShare/updateLinkShare.feature:73](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/updateLinkShare.feature#L73)
|
||||
- [apiSharingNgLinkShare/updateLinkShare.feature:75](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/updateLinkShare.feature#L75)
|
||||
- [apiSharingNgLinkShare/updateLinkShare.feature:76](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/updateLinkShare.feature#L76)
|
||||
- [apiSharingNgLinkShare/updateLinkShare.feature:77](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/updateLinkShare.feature#L77)
|
||||
- [apiSharingNgLinkShare/updateLinkShare.feature:143](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/updateLinkShare.feature#L143)
|
||||
- [apiSharingNgLinkShare/updateLinkShare.feature:468](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/updateLinkShare.feature#L468)
|
||||
- [apiSharingNgLinkShare/updateLinkShare.feature:855](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNgLinkShare/updateLinkShare.feature#L855)
|
||||
- [apiSharingNg/removeAccessToDriveItem.feature:125](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNg/removeAccessToDriveItem.feature#L125)
|
||||
- [apiSharingNg/removeAccessToDriveItem.feature:141](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNg/removeAccessToDriveItem.feature#L141)
|
||||
- [apiSharingNg/removeAccessToDriveItem.feature:161](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSharingNg/removeAccessToDriveItem.feature#L161)
|
||||
|
||||
@@ -474,270 +474,6 @@ Feature: Create a link share for a resource
|
||||
| internal |
|
||||
| blocksDownload |
|
||||
|
||||
@issue-7879
|
||||
Scenario Outline: update role of a file's link share using permissions endpoint
|
||||
Given user "Alice" has uploaded file with content "other data" to "textfile1.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": ""
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
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
|
||||
Given user "Alice" has uploaded file with content "other data" to "textfile1.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | internal |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": false
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": ""
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "internal"
|
||||
},
|
||||
"webUrl": {
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role |
|
||||
| view |
|
||||
| edit |
|
||||
| blocksDownload |
|
||||
|
||||
|
||||
Scenario: update expiration date of a file's link share using permissions endpoint
|
||||
Given user "Alice" has uploaded file with content "other data" to "textfile1.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | view |
|
||||
| password | %public% |
|
||||
| expirationDateTime | 2200-07-15T14:00:00.000Z |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| expirationDateTime | 2201-07-15T14:00:00.000Z |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"expirationDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"expirationDateTime": {
|
||||
"const": "2201-07-15T23:59:59Z"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "view"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
|
||||
@issues-8405
|
||||
Scenario Outline: remove expiration date of a resource link share using permissions endpoint
|
||||
Given user "Alice" has uploaded file with content "other data" to "textfile1.txt"
|
||||
And user "Alice" has created folder "folder"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | <resource> |
|
||||
| space | Personal |
|
||||
| permissionsRole | view |
|
||||
| password | %public% |
|
||||
| expirationDateTime | 2200-07-15T14:00:00.000Z |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | <resource> |
|
||||
| space | Personal |
|
||||
| expirationDateTime | |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "view"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| resource |
|
||||
| textfile1.txt |
|
||||
| folder |
|
||||
|
||||
@env-config
|
||||
Scenario: set password on a file's link share using permissions endpoint
|
||||
Given the following configs have been set:
|
||||
@@ -769,37 +505,6 @@ 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"
|
||||
|
||||
|
||||
Scenario: update password of a file's link share using permissions endpoint
|
||||
Given user "Alice" has uploaded file with content "other data" to "textfile1.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | view |
|
||||
| password | $heLlo*1234* |
|
||||
When user "Alice" sets the following password for the last link share using the Graph API:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| password | %public% |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
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
|
||||
|
||||
|
||||
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 "OCIS_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"
|
||||
@@ -842,54 +547,6 @@ Feature: Create a link share for a resource
|
||||
| password |
|
||||
| ownCloud |
|
||||
|
||||
|
||||
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 "OCIS_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"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | text.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | view |
|
||||
| password | %public% |
|
||||
When user "Alice" sets the following password for the last link share using the Graph API:
|
||||
| resource | text.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | view |
|
||||
| password | <banned-password> |
|
||||
Then the HTTP status code should be "400"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"error"
|
||||
],
|
||||
"properties": {
|
||||
"error": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"code",
|
||||
"message"
|
||||
],
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"pattern": "invalidRequest"
|
||||
},
|
||||
"message": {
|
||||
"const": "unfortunately, your password is commonly used. please pick a harder-to-guess password for your safety"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| banned-password |
|
||||
| 123 |
|
||||
| password |
|
||||
| ownCloud |
|
||||
|
||||
@issue-7879
|
||||
Scenario Outline: create a link share of a folder inside project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
@@ -1162,41 +819,6 @@ Feature: Create a link share for a resource
|
||||
| password | blocksDownload |
|
||||
| ownCloud | blocksDownload |
|
||||
|
||||
@env-config
|
||||
Scenario: set password on a existing link share of a folder inside project-space using permissions endpoint
|
||||
Given the following configs have been set:
|
||||
| config | value |
|
||||
| OCIS_SHARING_PUBLIC_SHARE_MUST_HAVE_PASSWORD | false |
|
||||
And using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has created a folder "folderToShare" in space "projectSpace"
|
||||
And user "Alice" has uploaded a file inside space "projectSpace" with content "to share" to "folderToShare/textfile.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | view |
|
||||
When user "Alice" sets the following password for the last link share using the Graph API:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| password | %public% |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
And the public should be able to download file "/textfile.txt" from the last link share with password "%public%" and the content should be "to share"
|
||||
|
||||
@env-config @issue-7879
|
||||
Scenario Outline: create a link share of a file inside project-space without password using permissions endpoint
|
||||
Given the following configs have been set:
|
||||
@@ -2239,69 +1861,6 @@ Feature: Create a link share for a resource
|
||||
| createOnly |
|
||||
| blocksDownload |
|
||||
|
||||
@env-config
|
||||
Scenario: set password on a existing link share of a project-space drive using root endpoint
|
||||
Given the following configs have been set:
|
||||
| config | value |
|
||||
| OCIS_SHARING_PUBLIC_SHARE_MUST_HAVE_PASSWORD | false |
|
||||
And using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has uploaded a file inside space "projectSpace" with content "to share" to "textfile.txt"
|
||||
And user "Alice" has created the following space link share:
|
||||
| space | projectSpace |
|
||||
| permissionsRole | view |
|
||||
When user "Alice" sets the following password for the last space link share using root endpoint of the Graph API:
|
||||
| space | projectSpace |
|
||||
| password | %public% |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
And the public should be able to download file "textfile.txt" from the last link share with password "%public%" and the content should be "to share"
|
||||
|
||||
|
||||
Scenario: update password on a existing link share of a project-space drive using root endpoint
|
||||
And using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has uploaded a file inside space "projectSpace" with content "to share" to "textfile.txt"
|
||||
And user "Alice" has created the following space link share:
|
||||
| space | projectSpace |
|
||||
| permissionsRole | view |
|
||||
| password | $heLlo*1234* |
|
||||
When user "Alice" sets the following password for the last space link share using root endpoint of the Graph API:
|
||||
| space | projectSpace |
|
||||
| password | %public% |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
And the public should be able to download file "textfile.txt" from the last link share with password "%public%" and the content should be "to share"
|
||||
And the public download of file "textfile.txt" from the last link share with password "$heLlo*1234*" should fail with HTTP status code "401" using shareNg
|
||||
|
||||
@issue-7879
|
||||
Scenario Outline: try to create a link share of a Personal and Shares drives using permissions endpoint
|
||||
When user "Alice" tries to create the following space link share using permissions endpoint of the Graph API:
|
||||
@@ -2804,394 +2363,6 @@ Feature: Create a link share for a resource
|
||||
| blocksDownload |
|
||||
|
||||
|
||||
Scenario Outline: update link share of a project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has created the following space link share:
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| password | %public% |
|
||||
| displayName | Homework |
|
||||
| expirationDateTime | 2200-07-15T14:00:00.000Z |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
| password | p@$$w0rD |
|
||||
| expirationDateTime | 2201-07-15T14:00:00Z |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"expirationDateTime",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"expirationDateTime": {
|
||||
"const": "2201-07-15T23:59:59Z"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Homework"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | edit |
|
||||
| view | upload |
|
||||
| view | createOnly |
|
||||
| edit | view |
|
||||
| edit | upload |
|
||||
| edit | createOnly |
|
||||
| upload | view |
|
||||
| upload | edit |
|
||||
| upload | createOnly |
|
||||
| createOnly | view |
|
||||
| createOnly | edit |
|
||||
| createOnly | upload |
|
||||
| blocksDownload | blocksDownload |
|
||||
|
||||
|
||||
Scenario Outline: update role of a folder's link share inside project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has created a folder "folderToShare" in space "projectSpace"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| displayName | Link |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"expirationDateTime": {
|
||||
"const": "2201-07-15T23:59:59Z"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Link"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | edit |
|
||||
| view | upload |
|
||||
| view | createOnly |
|
||||
| edit | view |
|
||||
| edit | upload |
|
||||
| edit | createOnly |
|
||||
| upload | view |
|
||||
| upload | edit |
|
||||
| upload | createOnly |
|
||||
| createOnly | view |
|
||||
| createOnly | edit |
|
||||
| createOnly | upload |
|
||||
|
||||
|
||||
Scenario Outline: update role of a file's link share inside a project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has uploaded a file inside space "projectSpace" with content "to share" to "textfile.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile.txt |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| displayName | Link |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | textfile.txt |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Link"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | edit |
|
||||
| edit | view |
|
||||
|
||||
|
||||
Scenario Outline: update role of a file's link share to internal inside a project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has uploaded a file inside space "projectSpace" with content "to share" to "textfile.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile.txt |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| displayName | Link |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | textfile.txt |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": false
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Link"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | internal |
|
||||
| edit | internal |
|
||||
|
||||
|
||||
Scenario Outline: update role of a folder's link share to internal inside project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has created a folder "folderToShare" in space "projectSpace"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| displayName | Link |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": false
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"expirationDateTime": {
|
||||
"const": "2201-07-15T23:59:59Z"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Link"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | internal |
|
||||
| edit | internal |
|
||||
| upload | internal |
|
||||
| createOnly | internal |
|
||||
|
||||
|
||||
Scenario Outline: create a quick link share of a folder using permissions endpoint
|
||||
Given user "Alice" has created folder "folder"
|
||||
When user "Alice" creates the following resource link share using the Graph API:
|
||||
@@ -3943,88 +3114,3 @@ Feature: Create a link share for a resource
|
||||
}
|
||||
}
|
||||
"""
|
||||
|
||||
|
||||
Scenario Outline: update link share of a folder inside personal drive using permissions endpoint
|
||||
Given user "Alice" has created folder "folder"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| space | Personal |
|
||||
| resource | folder |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| password | %public% |
|
||||
| displayName | Homework |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| space | Personal |
|
||||
| resource | folder |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
| password | p@$$w0rD |
|
||||
| expirationDateTime | 2201-07-15T14:00:00Z |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"expirationDateTime",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"expirationDateTime": {
|
||||
"const": "2201-07-15T23:59:59Z"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Homework"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | edit |
|
||||
| view | upload |
|
||||
| view | createOnly |
|
||||
| edit | view |
|
||||
| edit | upload |
|
||||
| edit | createOnly |
|
||||
| upload | view |
|
||||
| upload | edit |
|
||||
| upload | createOnly |
|
||||
| createOnly | view |
|
||||
| createOnly | edit |
|
||||
| createOnly | upload |
|
||||
| blocksDownload | blocksDownload |
|
||||
@@ -0,0 +1,920 @@
|
||||
Feature: Update a link share for a resource
|
||||
https://owncloud.dev/libre-graph-api/#/drives.permissions/CreateLink
|
||||
|
||||
Background:
|
||||
Given these users have been created with default attributes and without skeleton files:
|
||||
| username |
|
||||
| Alice |
|
||||
|
||||
@issue-7879
|
||||
Scenario Outline: update role of a file's link share using permissions endpoint
|
||||
Given user "Alice" has uploaded file with content "other data" to "textfile1.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": ""
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
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
|
||||
Given user "Alice" has uploaded file with content "other data" to "textfile1.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | internal |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": false
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": ""
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "internal"
|
||||
},
|
||||
"webUrl": {
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role |
|
||||
| view |
|
||||
| edit |
|
||||
| blocksDownload |
|
||||
|
||||
|
||||
Scenario: update expiration date of a file's link share using permissions endpoint
|
||||
Given user "Alice" has uploaded file with content "other data" to "textfile1.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | view |
|
||||
| password | %public% |
|
||||
| expirationDateTime | 2200-07-15T14:00:00.000Z |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| expirationDateTime | 2201-07-15T14:00:00.000Z |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"expirationDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"expirationDateTime": {
|
||||
"const": "2201-07-15T23:59:59Z"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "view"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
|
||||
|
||||
Scenario: update password of a file's link share using permissions endpoint
|
||||
Given user "Alice" has uploaded file with content "other data" to "textfile1.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | view |
|
||||
| password | $heLlo*1234* |
|
||||
When user "Alice" sets the following password for the last link share using the Graph API:
|
||||
| resource | textfile1.txt |
|
||||
| space | Personal |
|
||||
| password | %public% |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
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
|
||||
|
||||
|
||||
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 "OCIS_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"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | text.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | view |
|
||||
| password | %public% |
|
||||
When user "Alice" sets the following password for the last link share using the Graph API:
|
||||
| resource | text.txt |
|
||||
| space | Personal |
|
||||
| permissionsRole | view |
|
||||
| password | <banned-password> |
|
||||
Then the HTTP status code should be "400"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"error"
|
||||
],
|
||||
"properties": {
|
||||
"error": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"code",
|
||||
"message"
|
||||
],
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"pattern": "invalidRequest"
|
||||
},
|
||||
"message": {
|
||||
"const": "unfortunately, your password is commonly used. please pick a harder-to-guess password for your safety"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| banned-password |
|
||||
| 123 |
|
||||
| password |
|
||||
| ownCloud |
|
||||
|
||||
@env-config
|
||||
Scenario: set password on a existing link share of a folder inside project-space using permissions endpoint
|
||||
Given the following configs have been set:
|
||||
| config | value |
|
||||
| OCIS_SHARING_PUBLIC_SHARE_MUST_HAVE_PASSWORD | false |
|
||||
And using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has created a folder "folderToShare" in space "projectSpace"
|
||||
And user "Alice" has uploaded a file inside space "projectSpace" with content "to share" to "folderToShare/textfile.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | view |
|
||||
When user "Alice" sets the following password for the last link share using the Graph API:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| password | %public% |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
And the public should be able to download file "/textfile.txt" from the last link share with password "%public%" and the content should be "to share"
|
||||
|
||||
@env-config
|
||||
Scenario: set password on a existing link share of a project-space drive using root endpoint
|
||||
Given the following configs have been set:
|
||||
| config | value |
|
||||
| OCIS_SHARING_PUBLIC_SHARE_MUST_HAVE_PASSWORD | false |
|
||||
And using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has uploaded a file inside space "projectSpace" with content "to share" to "textfile.txt"
|
||||
And user "Alice" has created the following space link share:
|
||||
| space | projectSpace |
|
||||
| permissionsRole | view |
|
||||
When user "Alice" sets the following password for the last space link share using root endpoint of the Graph API:
|
||||
| space | projectSpace |
|
||||
| password | %public% |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
And the public should be able to download file "textfile.txt" from the last link share with password "%public%" and the content should be "to share"
|
||||
|
||||
|
||||
Scenario: update password on a existing link share of a project-space drive using root endpoint
|
||||
And using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has uploaded a file inside space "projectSpace" with content "to share" to "textfile.txt"
|
||||
And user "Alice" has created the following space link share:
|
||||
| space | projectSpace |
|
||||
| permissionsRole | view |
|
||||
| password | $heLlo*1234* |
|
||||
When user "Alice" sets the following password for the last space link share using root endpoint of the Graph API:
|
||||
| space | projectSpace |
|
||||
| password | %public% |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
And the public should be able to download file "textfile.txt" from the last link share with password "%public%" and the content should be "to share"
|
||||
And the public download of file "textfile.txt" from the last link share with password "$heLlo*1234*" should fail with HTTP status code "401" using shareNg
|
||||
|
||||
@issue-7879
|
||||
Scenario Outline: update link share of a project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has created the following space link share:
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| password | %public% |
|
||||
| displayName | Homework |
|
||||
| expirationDateTime | 2200-07-15T14:00:00.000Z |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
| password | p@$$w0rD |
|
||||
| expirationDateTime | 2201-07-15T14:00:00Z |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"expirationDateTime",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"expirationDateTime": {
|
||||
"const": "2201-07-15T23:59:59Z"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Homework"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | edit |
|
||||
| view | upload |
|
||||
| view | createOnly |
|
||||
| edit | view |
|
||||
| edit | upload |
|
||||
| edit | createOnly |
|
||||
| upload | view |
|
||||
| upload | edit |
|
||||
| upload | createOnly |
|
||||
| createOnly | view |
|
||||
| createOnly | edit |
|
||||
| createOnly | upload |
|
||||
| blocksDownload | blocksDownload |
|
||||
|
||||
|
||||
Scenario Outline: update role of a folder's link share inside project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has created a folder "folderToShare" in space "projectSpace"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| displayName | Link |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"expirationDateTime": {
|
||||
"const": "2201-07-15T23:59:59Z"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Link"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | edit |
|
||||
| view | upload |
|
||||
| view | createOnly |
|
||||
| edit | view |
|
||||
| edit | upload |
|
||||
| edit | createOnly |
|
||||
| upload | view |
|
||||
| upload | edit |
|
||||
| upload | createOnly |
|
||||
| createOnly | view |
|
||||
| createOnly | edit |
|
||||
| createOnly | upload |
|
||||
|
||||
|
||||
Scenario Outline: update role of a file's link share inside a project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has uploaded a file inside space "projectSpace" with content "to share" to "textfile.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile.txt |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| displayName | Link |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | textfile.txt |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Link"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | edit |
|
||||
| edit | view |
|
||||
|
||||
|
||||
Scenario Outline: update role of a file's link share to internal inside a project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has uploaded a file inside space "projectSpace" with content "to share" to "textfile.txt"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | textfile.txt |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| displayName | Link |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | textfile.txt |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": false
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Link"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | internal |
|
||||
| edit | internal |
|
||||
|
||||
|
||||
Scenario Outline: update role of a folder's link share to internal inside project-space using permissions endpoint
|
||||
Given using spaces DAV path
|
||||
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
|
||||
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
|
||||
And user "Alice" has created a folder "folderToShare" in space "projectSpace"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| displayName | Link |
|
||||
| password | %public% |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | folderToShare |
|
||||
| space | projectSpace |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": false
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"expirationDateTime": {
|
||||
"const": "2201-07-15T23:59:59Z"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Link"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | internal |
|
||||
| edit | internal |
|
||||
| upload | internal |
|
||||
| createOnly | internal |
|
||||
|
||||
|
||||
Scenario Outline: update link share of a folder inside personal drive using permissions endpoint
|
||||
Given user "Alice" has created folder "folder"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| space | Personal |
|
||||
| resource | folder |
|
||||
| permissionsRole | <permissions-role> |
|
||||
| password | %public% |
|
||||
| displayName | Homework |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| space | Personal |
|
||||
| resource | folder |
|
||||
| permissionsRole | <new-permissions-role> |
|
||||
| password | p@$$w0rD |
|
||||
| expirationDateTime | 2201-07-15T14:00:00Z |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link",
|
||||
"expirationDateTime",
|
||||
"createdDateTime"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"expirationDateTime": {
|
||||
"const": "2201-07-15T23:59:59Z"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.displayName": {
|
||||
"const": "Homework"
|
||||
},
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "<new-permissions-role>"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| permissions-role | new-permissions-role |
|
||||
| view | edit |
|
||||
| view | upload |
|
||||
| view | createOnly |
|
||||
| edit | view |
|
||||
| edit | upload |
|
||||
| edit | createOnly |
|
||||
| upload | view |
|
||||
| upload | edit |
|
||||
| upload | createOnly |
|
||||
| createOnly | view |
|
||||
| createOnly | edit |
|
||||
| createOnly | upload |
|
||||
| blocksDownload | blocksDownload |
|
||||
|
||||
@issues-8405
|
||||
Scenario Outline: remove expiration date of a resource link share using permissions endpoint
|
||||
Given user "Alice" has uploaded file with content "other data" to "textfile1.txt"
|
||||
And user "Alice" has created folder "folder"
|
||||
And user "Alice" has created the following resource link share:
|
||||
| resource | <resource> |
|
||||
| space | Personal |
|
||||
| permissionsRole | view |
|
||||
| password | %public% |
|
||||
| expirationDateTime | 2200-07-15T14:00:00.000Z |
|
||||
When user "Alice" updates the last public link share using the permissions endpoint of the Graph API:
|
||||
| resource | <resource> |
|
||||
| space | Personal |
|
||||
| expirationDateTime | |
|
||||
Then the HTTP status code should be "200"
|
||||
And the JSON data of the response should match
|
||||
"""
|
||||
{
|
||||
"type": "object",
|
||||
"required": [
|
||||
"hasPassword",
|
||||
"id",
|
||||
"link"
|
||||
],
|
||||
"properties": {
|
||||
"hasPassword": {
|
||||
"const": true
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"pattern": "^[a-zA-Z]{15}$"
|
||||
},
|
||||
"link": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"@libre.graph.displayName",
|
||||
"@libre.graph.quickLink",
|
||||
"preventsDownload",
|
||||
"type",
|
||||
"webUrl"
|
||||
],
|
||||
"properties": {
|
||||
"@libre.graph.quickLink": {
|
||||
"const": false
|
||||
},
|
||||
"preventsDownload": {
|
||||
"const": false
|
||||
},
|
||||
"type": {
|
||||
"const": "view"
|
||||
},
|
||||
"webUrl": {
|
||||
"type": "string",
|
||||
"pattern": "^%base_url%/s/[a-zA-Z]{15}$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
Examples:
|
||||
| resource |
|
||||
| textfile1.txt |
|
||||
| folder |
|
||||
Reference in New Issue
Block a user