@@ -6,137 +6,22 @@ Feature: List a federated sharing permissions
6
6
7
7
Background :
8
8
Given user "Alice" has been created with default attributes
9
-
10
-
11
- Scenario : user lists permissions of a resource shared to a federated user
12
- Given using server "LOCAL"
13
9
And "Alice" has created the federation share invitation
14
10
And using server "REMOTE"
15
11
And user "Brian" has been created with default attributes
16
12
And "Brian" has accepted invitation
17
- And using server "LOCAL"
18
- And user "Alice" has uploaded file with content "ocm test" to "/textfile.txt"
19
- And user "Alice" has sent the following resource share invitation to federated user:
20
- | resource | textfile .txt |
21
- | space | Personal |
22
- | sharee | Brian |
23
- | shareType | user |
24
- | permissionsRole | Viewer |
25
- When user "Alice" gets permissions list for file "textfile.txt" of the space "Personal" using the Graph API
26
- Then the HTTP status code should be "200"
27
- And the JSON data of the response should match
28
- """
29
- {
30
- "type": "object",
31
- "required": [
32
- "@libre.graph.permissions.actions.allowedValues",
33
- "@libre.graph.permissions.roles.allowedValues",
34
- "value"
35
- ],
36
- "properties": {
37
- "value": {
38
- "type": "array",
39
- "minItems": 1,
40
- "maxItems": 1,
41
- "uniqueItems": true,
42
- "items": {
43
- "oneOf":[
44
- {
45
- "type": "object",
46
- "required": [
47
- "grantedToV2",
48
- "id",
49
- "roles"
50
- ],
51
- "properties": {
52
- "grantedToV2": {
53
- "type": "object",
54
- "required": ["user"],
55
- "properties": {
56
- "user": {
57
- "type": "object",
58
- "required": ["@libre.graph.userType","displayName","id"],
59
- "properties": {
60
- "@libre.graph.userType": {
61
- "const": "Federated"
62
- },
63
- "id": {
64
- "type": "string",
65
- "pattern": "^%federated_user_id_pattern%$"
66
- },
67
- "displayName": {
68
- "const": "Brian Murphy"
69
- }
70
- }
71
- }
72
- }
73
- },
74
- "id": {
75
- "type": "string",
76
- "pattern": "^%user_id_pattern%$"
77
- },
78
- "invitation": {
79
- "type": "object",
80
- "required": ["invitedBy"],
81
- "properties": {
82
- "invitedBy": {
83
- "type": "object",
84
- "required": ["user"],
85
- "properties": {
86
- "user": {
87
- "type": "object",
88
- "required": ["@libre.graph.userType", "displayName", "id"],
89
- "properties": {
90
- "@libre.graph.userType": {
91
- "const": "Member"
92
- },
93
- "id": {
94
- "type": "string",
95
- "pattern": "^%user_id_pattern%$"
96
- },
97
- "displayName": {
98
- "const": "Alice Hansen"
99
- }
100
- }
101
- }
102
- }
103
- }
104
- }
105
- },
106
- "roles": {
107
- "type": "array",
108
- "minItems": 1,
109
- "maxItems": 1,
110
- "items": {
111
- "type": "string",
112
- "pattern": "^%role_id_pattern%$"
113
- }
114
- }
115
- }
116
- }
117
- ]
118
- }
119
- }
120
- }
121
- }
122
- """
123
13
124
14
125
15
Scenario : user lists permissions of a resource shared to a federated user
126
16
Given using server "LOCAL"
127
- And "Alice" has created the federation share invitation
128
- And using server "REMOTE"
129
- And user "Brian" has been created with default attributes
130
- And "Brian" has accepted invitation
131
- And using server "LOCAL"
132
- And user "Alice" has created folder "/uploadFolder"
17
+ And user "Alice" has uploaded file with content "ocm test" to "/textfile.txt"
133
18
And user "Alice" has sent the following resource share invitation to federated user:
134
- | resource | uploadFolder |
19
+ | resource | textfile . txt |
135
20
| space | Personal |
136
21
| sharee | Brian |
137
22
| shareType | user |
138
- | permissionsRole | Editor |
139
- When user "Alice" gets permissions list for folder "uploadFolder " of the space "Personal" using the Graph API
23
+ | permissionsRole | Viewer |
24
+ When user "Alice" gets permissions list for file "textfile.txt " of the space "Personal" using the Graph API
140
25
Then the HTTP status code should be "200"
141
26
And the JSON data of the response should match
142
27
"""
@@ -157,11 +42,7 @@ Feature: List a federated sharing permissions
157
42
"oneOf":[
158
43
{
159
44
"type": "object",
160
- "required": [
161
- "grantedToV2",
162
- "id",
163
- "roles"
164
- ],
45
+ "required": ["grantedToV2","id","roles"],
165
46
"properties": {
166
47
"grantedToV2": {
167
48
"type": "object",
@@ -171,24 +52,14 @@ Feature: List a federated sharing permissions
171
52
"type": "object",
172
53
"required": ["@libre.graph.userType","displayName","id"],
173
54
"properties": {
174
- "@libre.graph.userType": {
175
- "const": "Federated"
176
- },
177
- "id": {
178
- "type": "string",
179
- "pattern": "^%federated_user_id_pattern%$"
180
- },
181
- "displayName": {
182
- "const": "Brian Murphy"
183
- }
55
+ "@libre.graph.userType": {"const": "Federated"},
56
+ "id": {"pattern": "^%federated_user_id_pattern%$"},
57
+ "displayName": {"const": "Brian Murphy"}
184
58
}
185
59
}
186
60
}
187
61
},
188
- "id": {
189
- "type": "string",
190
- "pattern": "^%user_id_pattern%$"
191
- },
62
+ "id": {"pattern": "^%user_id_pattern%$"},
192
63
"invitation": {
193
64
"type": "object",
194
65
"required": ["invitedBy"],
@@ -201,16 +72,9 @@ Feature: List a federated sharing permissions
201
72
"type": "object",
202
73
"required": ["@libre.graph.userType", "displayName", "id"],
203
74
"properties": {
204
- "@libre.graph.userType": {
205
- "const": "Member"
206
- },
207
- "id": {
208
- "type": "string",
209
- "pattern": "^%user_id_pattern%$"
210
- },
211
- "displayName": {
212
- "const": "Alice Hansen"
213
- }
75
+ "@libre.graph.userType": {"const": "Member"},
76
+ "id": {"pattern": "^%user_id_pattern%$"},
77
+ "displayName": {"const": "Alice Hansen"}
214
78
}
215
79
}
216
80
}
@@ -221,10 +85,7 @@ Feature: List a federated sharing permissions
221
85
"type": "array",
222
86
"minItems": 1,
223
87
"maxItems": 1,
224
- "items": {
225
- "type": "string",
226
- "pattern": "^%role_id_pattern%$"
227
- }
88
+ "items": {"pattern": "^%role_id_pattern%$"}
228
89
}
229
90
}
230
91
}
@@ -238,11 +99,6 @@ Feature: List a federated sharing permissions
238
99
239
100
Scenario : user lists permissions of a project resource shared to a federated user
240
101
Given using server "LOCAL"
241
- And "Alice" has created the federation share invitation
242
- And using server "REMOTE"
243
- And user "Brian" has been created with default attributes
244
- And "Brian" has accepted invitation
245
- And using server "LOCAL"
246
102
And using spaces DAV path
247
103
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
248
104
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
@@ -288,24 +144,14 @@ Feature: List a federated sharing permissions
288
144
"type": "object",
289
145
"required": ["@libre.graph.userType","displayName","id"],
290
146
"properties": {
291
- "@libre.graph.userType": {
292
- "const": "Federated"
293
- },
294
- "id": {
295
- "type": "string",
296
- "pattern": "^%federated_user_id_pattern%$"
297
- },
298
- "displayName": {
299
- "const": "Brian Murphy"
300
- }
147
+ "@libre.graph.userType": {"const": "Federated"},
148
+ "id": {"pattern": "^%federated_user_id_pattern%$"},
149
+ "displayName": {"const": "Brian Murphy"}
301
150
}
302
151
}
303
152
}
304
153
},
305
- "id": {
306
- "type": "string",
307
- "pattern": "^%user_id_pattern%$"
308
- },
154
+ "id": { "pattern": "^%user_id_pattern%$" },
309
155
"invitation": {
310
156
"type": "object",
311
157
"required": ["invitedBy"],
@@ -318,14 +164,9 @@ Feature: List a federated sharing permissions
318
164
"type": "object",
319
165
"required": ["@libre.graph.userType", "displayName", "id"],
320
166
"properties": {
321
- "@libre.graph.userType": {
322
- "const": "Member"
323
- },
324
- "id": {
325
- "type": "string",
326
- "pattern": "^%user_id_pattern%$"
327
- },
328
- "displayName": { "const": "Alice Hansen" }
167
+ "@libre.graph.userType": {"const": "Member"},
168
+ "id": {"pattern": "^%user_id_pattern%$"},
169
+ "displayName": {"const": "Alice Hansen"}
329
170
}
330
171
}
331
172
}
@@ -336,7 +177,7 @@ Feature: List a federated sharing permissions
336
177
"type": "array",
337
178
"minItems": 1,
338
179
"maxItems": 1,
339
- "items": { "pattern": "^%role_id_pattern%$" }
180
+ "items": {"pattern": "^%role_id_pattern%$"}
340
181
}
341
182
}
342
183
}
@@ -350,11 +191,6 @@ Feature: List a federated sharing permissions
350
191
351
192
Scenario : user lists permissions of a project resource shared to a federated user
352
193
Given using server "LOCAL"
353
- And "Alice" has created the federation share invitation
354
- And using server "REMOTE"
355
- And user "Brian" has been created with default attributes
356
- And "Brian" has accepted invitation
357
- And using server "LOCAL"
358
194
And using spaces DAV path
359
195
And the administrator has assigned the role "Space Admin" to user "Alice" using the Graph API
360
196
And user "Alice" has created a space "projectSpace" with the default quota using the Graph API
@@ -386,7 +222,7 @@ Feature: List a federated sharing permissions
386
222
"oneOf":[
387
223
{
388
224
"type": "object",
389
- "required": ["grantedToV2", "id", "roles"],
225
+ "required": ["grantedToV2","id","roles"],
390
226
"properties": {
391
227
"grantedToV2": {
392
228
"type": "object",
@@ -396,14 +232,14 @@ Feature: List a federated sharing permissions
396
232
"type": "object",
397
233
"required": ["@libre.graph.userType","displayName","id"],
398
234
"properties": {
399
- "@libre.graph.userType": { "const": "Federated" },
400
- "id": { "pattern": "^%federated_user_id_pattern%$" },
401
- "displayName": { "const": "Brian Murphy" }
235
+ "@libre.graph.userType": {"const": "Federated"},
236
+ "id": {"pattern": "^%federated_user_id_pattern%$"},
237
+ "displayName": {"const": "Brian Murphy"}
402
238
}
403
239
}
404
240
}
405
241
},
406
- "id": { "pattern": "^%user_id_pattern%$" },
242
+ "id": {"pattern": "^%user_id_pattern%$"},
407
243
"invitation": {
408
244
"type": "object",
409
245
"required": ["invitedBy"],
@@ -416,9 +252,9 @@ Feature: List a federated sharing permissions
416
252
"type": "object",
417
253
"required": ["@libre.graph.userType", "displayName", "id"],
418
254
"properties": {
419
- "@libre.graph.userType": { "const": "Member" },
420
- "id": { "pattern": "^%user_id_pattern%$" },
421
- "displayName": { "const": "Alice Hansen" }
255
+ "@libre.graph.userType": {"const": "Member"},
256
+ "id": {"pattern": "^%user_id_pattern%$"},
257
+ "displayName": {"const": "Alice Hansen"}
422
258
}
423
259
}
424
260
}
@@ -429,7 +265,7 @@ Feature: List a federated sharing permissions
429
265
"type": "array",
430
266
"minItems": 1,
431
267
"maxItems": 1,
432
- "items": { "pattern": "^%role_id_pattern%$" }
268
+ "items": {"pattern": "^%role_id_pattern%$"}
433
269
}
434
270
}
435
271
}
0 commit comments