opengate-js 14.0.0 → 14.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. package/bower.json +1 -1
  2. package/dist/{opengate-api-bower-14.0.0.js → opengate-api-bower-14.2.0.js} +26 -21
  3. package/dist/opengate-api-bower-14.2.0.js.map +1 -0
  4. package/dist/{opengate-api-bower-14.0.0.min.js → opengate-api-bower-14.2.0.min.js} +2 -2
  5. package/dist/{opengate-api-bower-14.0.0.min.js.map → opengate-api-bower-14.2.0.min.js.map} +1 -1
  6. package/dist/src/operations/OperationActions.js +2 -0
  7. package/dist/src/operations/OperationActions.js.map +1 -1
  8. package/dist/src/operations/catalog/BaseOperationBuilder.js +14 -11
  9. package/dist/src/operations/catalog/BaseOperationBuilder.js.map +1 -1
  10. package/dist/src/searching/StaticSearch.js +4 -4
  11. package/dist/src/searching/StaticSearch.js.map +1 -1
  12. package/docs/ast/source/operations/OperationActions.js.json +8300 -7782
  13. package/docs/ast/source/operations/catalog/BaseOperationBuilder.js.json +10013 -9786
  14. package/docs/ast/source/searching/StaticSearch.js.json +18177 -18127
  15. package/docs/class/src/operations/OperationActions.js~OperationActions.html +2 -2
  16. package/docs/class/src/operations/catalog/BaseOperationBuilder.js~BaseOperationBuilder.html +22 -15
  17. package/docs/coverage.json +1 -1
  18. package/docs/dump.json +1971 -1915
  19. package/docs/file/src/operations/OperationActions.js.html +2 -0
  20. package/docs/file/src/operations/catalog/BaseOperationBuilder.js.html +12 -11
  21. package/docs/file/src/searching/StaticSearch.js.html +4 -4
  22. package/docs/package.json +1 -1
  23. package/docs/source.html +240 -240
  24. package/features/features/provision/operations/actions_execution.feature +105 -52
  25. package/features/features/provision/operations/execute_operations.feature +152 -112
  26. package/features/features/provision/operations/execute_periodic_operations.feature +115 -64
  27. package/features/features/provision/operations/find_execution.feature +49 -11
  28. package/features/features/provision/operations/find_executions.feature +51 -11
  29. package/features/features/provision/operations/find_periodic_execution.feature +48 -11
  30. package/features/features/provision/operations/setting_up_period-each_operation.feature +88 -23
  31. package/features/features/provision/operations/update_periodic_operation.feature +88 -46
  32. package/features/features/provision/users/update_password.feature +0 -1
  33. package/features/features/provision/users/update_user.feature +0 -1
  34. package/features/features/searching/operations/searching_executions.feature +47 -7
  35. package/features/features/searching/operations/searching_periodic_operations.feature +51 -10
  36. package/features/step_definitions/given_step_definitions.js +12 -5
  37. package/features/step_definitions/then_step_definitions.js +44 -35
  38. package/features/step_definitions/when_step_definitions.js +16 -10
  39. package/features/support/create_provision_model.js +6 -0
  40. package/features/support/find_model.js +4 -0
  41. package/features/support/utils_model.js +26 -20
  42. package/features/support/world.js +2 -2
  43. package/package.json +1 -1
  44. package/src/operations/OperationActions.js +2 -0
  45. package/src/operations/catalog/BaseOperationBuilder.js +12 -11
  46. package/src/searching/StaticSearch.js +4 -4
  47. package/yarn-error.log +7437 -0
  48. package/dist/opengate-api-bower-14.0.0.js.map +0 -1
@@ -12,8 +12,7 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
12
12
  Background:
13
13
  Given an apikey user by "require-real-apikey"
14
14
 
15
-
16
- Scenario: Creating an organization to use in create device
15
+ Scenario: Precondition - Creating an organization to use in create device
17
16
  Given an ogapi "organizations builder" util
18
17
  Then I want to create an "organization"
19
18
  And the "name" "execute_periodic_organization_10"
@@ -27,7 +26,25 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
27
26
  Then I create it
28
27
  And response code should be: 201
29
28
 
30
- Scenario: I want to create an entity
29
+ Scenario: Precondition - Create and delete an user that does not exist
30
+ And an ogapi "users builder" util
31
+ And I want to create a "user"
32
+ And the "email" "ogux_ogapi@amplia.com"
33
+ And the "password" "Nvoiqewvouoiu32j@#!!"
34
+ And the "workgroup" "execute_periodic_organization_10"
35
+ And the "domain" "execute_periodic_organization_10"
36
+ And the "profile" "admin_domain"
37
+ And the "countryCode" "ES"
38
+ And the "langCode" "en"
39
+ And the "name" "test name"
40
+ And the "surname" "test surname"
41
+ And the "description" "user description"
42
+ Then I delete it
43
+ And I create it
44
+ Then response code should be: 201
45
+
46
+ Scenario: Precondition - I want to create an entity
47
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
31
48
  Given the entity of type "devices builder" with "execute_periodic_organization_10"
32
49
  And I get allowed Datastreams fields
33
50
  And I can found "provision.device.identifier" as datastream name
@@ -36,7 +53,7 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
36
53
  | provision.administration.channel | simple | default_channel | |
37
54
  | provision.administration.organization | simple | execute_periodic_organization_10 | |
38
55
  | provision.administration.serviceGroup | simple | emptyServiceGroup | |
39
- | provision.device.identifier | simple | execute_periodic_device | |
56
+ | provision.device.identifier | simple | execute_periodic_device_C | |
40
57
  | provision.device.operationalStatus | simple | NORMAL | |
41
58
  | provision.device.administrativeState | simple | ACTIVE | |
42
59
 
@@ -44,15 +61,28 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
44
61
  And response code should be: 201
45
62
 
46
63
 
64
+
65
+ Scenario: Precondition - I want to create an operation Type
66
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
67
+ Given an ogapi "operation type" util with "execute_periodic_organization_10"
68
+ Then I want to create an "operation type"
69
+ And the "name" "ADMINISTRATIVE_STATUS_CHANGE_TEST"
70
+ And the "title" "Administrative status change test"
71
+ And the "description" "Allows to change the administrative status of an entity"
72
+ And the "fromCatalog" "ADMINISTRATIVE_STATUS_CHANGE"
73
+ Then I create it
74
+ And response code should be: 201
75
+
47
76
  Scenario: Execute periodic operation every day
48
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
77
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
78
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
49
79
  And the notes by ""
50
80
  And the timeout by 120000
51
81
  And the ackTimeout by 0
52
82
  And the retries by 0
53
83
  And the retriesDelay by 0
54
- And parameter "admsts" by "inventado"
55
- And the job timeout by 5 minutes
84
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
85
+ And the job timeout by 300 seconds
56
86
  And execute every day at "2020-01-10T21:44:13Z"
57
87
  And append entities by "{}" as filter with "entity.device" as resourceType
58
88
  When I build it
@@ -62,20 +92,21 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
62
92
  And an ogapi "operation finder" util
63
93
  And I want to read a "periodicity"
64
94
  When I try to find by operation's id
65
- Then I can see into the result an "periodic schedule" as
95
+ Then I can see into the result an "periodic schedule - repeating" as
66
96
  """
67
- {"start":{"date":"2020-01-10T21:44:13Z"},"repeating":{"period":null,"pattern":{"time":"22:44:13+01:00","definedPatternNumber":0}}}
97
+ {"period":null,"pattern":{"time":"22:44:13+01:00","definedPatternNumber":0}}
68
98
  """
69
99
 
70
100
  Scenario: Execute periodic operation every week
71
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
101
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
102
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
72
103
  And the notes by ""
73
104
  And the timeout by 120000
74
105
  And the ackTimeout by 0
75
106
  And the retries by 0
76
107
  And the retriesDelay by 0
77
- And parameter "admsts" by "inventado"
78
- And the job timeout by 5 minutes
108
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
109
+ And the job timeout by 300 seconds
79
110
  And execute every week at "2020-01-10T21:44:13Z" on days:
80
111
  | MON |
81
112
  | WED |
@@ -88,34 +119,36 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
88
119
  And an ogapi "operation finder" util
89
120
  And I want to read a "periodicity"
90
121
  When I try to find by operation's id
91
- Then I can see into the result an "periodic schedule" as
122
+ Then I can see into the result an "periodic schedule - repeating" as
92
123
  """
93
- {"start":{"date":"2020-01-10T21:44:13Z"},"repeating":{"period":null,"pattern":{"time":"22:44:13+01:00","weekly":{"days":["MON","WED","FRI"]},"definedPatternNumber":0}}}
124
+ {"period":null,"pattern":{"time":"22:44:13+01:00","weekly":{"days":["MON","WED","FRI"]},"definedPatternNumber":1}}
94
125
  """
95
126
 
96
127
  Scenario: Execute periodic operation every week and fail
97
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
128
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
129
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
98
130
  And the notes by ""
99
131
  And the timeout by 120000
100
132
  And the ackTimeout by 0
101
133
  And the retries by 0
102
134
  And the retriesDelay by 0
103
- And parameter "admsts" by "inventado"
104
- And the job timeout by 5 minutes
135
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
136
+ And the job timeout by 300 seconds
105
137
  When execute every week at on days:
106
138
  | FRI |
107
139
  | SUN |
108
140
  Then throws an error equal to "Parameter date must be typeof Date"
109
141
 
110
142
  Scenario: Execute periodic operation every month
111
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
143
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
144
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
112
145
  And the notes by ""
113
146
  And the timeout by 120000
114
147
  And the ackTimeout by 0
115
148
  And the retries by 0
116
149
  And the retriesDelay by 0
117
- And parameter "admsts" by "inventado"
118
- And the job timeout by 5 minutes
150
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
151
+ And the job timeout by 300 seconds
119
152
  And execute every month at "2020-01-10T21:44:13Z" at day 3 on months:
120
153
  | JAN |
121
154
  | MAR |
@@ -128,26 +161,27 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
128
161
  And an ogapi "operation finder" util
129
162
  And I want to read a "periodicity"
130
163
  When I try to find by operation's id
131
- Then I can see into the result an "periodic schedule" as
164
+ Then I can see into the result an "periodic schedule - repeating" as
132
165
  """
133
- {"start":{"date":"2020-01-10T21:44:13Z"},"repeating":{"period":null,"pattern":{"time":"22:44:13+01:00","monthly":{"day":3,"months":["JAN","MAR","MAY"]},"definedPatternNumber":0}}}
166
+ {"period":null,"pattern":{"time":"22:44:13+01:00","monthly":{"day":3,"months":["JAN","MAR","MAY"]},"definedPatternNumber":1}}
134
167
  """
135
168
 
136
169
  Scenario: Execute periodic operation every month without day and fail
137
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
170
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
171
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
138
172
  And the notes by ""
139
173
  And the timeout by 120000
140
174
  And the ackTimeout by 0
141
175
  And the retries by 0
142
176
  And the retriesDelay by 0
143
- And parameter "admsts" by "inventado"
144
- And the job timeout by 5 minutes
177
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
178
+ And the job timeout by 300 seconds
145
179
  And execute every month at "2020-02-10T21:44:13Z" on months:
146
180
  | FEB |
147
181
  | APR |
148
182
  | JUN |
149
183
  And append entities by:
150
- | execute_periodic_device |
184
+ | execute_periodic_device_C |
151
185
  When I build it
152
186
  And I execute it
153
187
  Then response code should be: 201
@@ -158,26 +192,28 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
158
192
  Then response code should be: 404
159
193
 
160
194
  Scenario: Execute periodic operation every month without months and fail
161
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
195
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
196
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
162
197
  And the notes by ""
163
198
  And the timeout by 120000
164
199
  And the ackTimeout by 0
165
200
  And the retries by 0
166
201
  And the retriesDelay by 0
167
- And parameter "admsts" by "inventado"
168
- And the job timeout by 5 minutes
202
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
203
+ And the job timeout by 300 seconds
169
204
  When execute every month at "2020-03-10T21:44:13Z" at day 5
170
205
  Then throws an error equal to "Parameter months must be typeof Array"
171
206
 
172
207
  Scenario: Execute periodic operation every month without start and fail
173
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
208
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
209
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
174
210
  And the notes by ""
175
211
  And the timeout by 120000
176
212
  And the ackTimeout by 0
177
213
  And the retries by 0
178
214
  And the retriesDelay by 0
179
- And parameter "admsts" by "inventado"
180
- And the job timeout by 5 minutes
215
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
216
+ And the job timeout by 300 seconds
181
217
  When execute every month at day 29 on months:
182
218
  | DEC |
183
219
  | OCT |
@@ -185,26 +221,28 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
185
221
  Then throws an error equal to "Parameter date must be typeof Date"
186
222
 
187
223
  Scenario: Execute periodic operation every month without start and month and fail
188
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
224
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
225
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
189
226
  And the notes by ""
190
227
  And the timeout by 120000
191
228
  And the ackTimeout by 0
192
229
  And the retries by 0
193
230
  And the retriesDelay by 0
194
- And parameter "admsts" by "inventado"
195
- And the job timeout by 5 minutes
231
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
232
+ And the job timeout by 300 seconds
196
233
  When execute every month at day 18
197
234
  Then throws an error equal to "Parameter date must be typeof Date"
198
235
 
199
236
  Scenario: Execute periodic operation every month without start and day and fail
200
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
237
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
238
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
201
239
  And the notes by ""
202
240
  And the timeout by 120000
203
241
  And the ackTimeout by 0
204
242
  And the retries by 0
205
243
  And the retriesDelay by 0
206
- And parameter "admsts" by "inventado"
207
- And the job timeout by 5 minutes
244
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
245
+ And the job timeout by 300 seconds
208
246
  When execute every month on months:
209
247
  | NOV |
210
248
  | SEP |
@@ -213,14 +251,15 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
213
251
 
214
252
 
215
253
  Scenario: Execute periodic operation every year
216
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
254
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
255
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
217
256
  And the notes by ""
218
257
  And the timeout by 120000
219
258
  And the ackTimeout by 0
220
259
  And the retries by 0
221
260
  And the retriesDelay by 0
222
- And parameter "admsts" by "inventado"
223
- And the job timeout by 5 minutes
261
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
262
+ And the job timeout by 300 seconds
224
263
  And execute every year at "2020-01-10T21:44:13Z" at day 4 on month "JAN"
225
264
  And append entities by "{}" as filter with "entity.device" as resourceType
226
265
  When I build it
@@ -233,23 +272,24 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
233
272
  And an ogapi "operation finder" util
234
273
  And I want to read a "periodicity"
235
274
  When I try to find by operation's id
236
- Then I can see into the result an "periodic schedule" as
275
+ Then I can see into the result an "periodic schedule - repeating" as
237
276
  """
238
- {"start":{"date":"2020-01-10T21:44:13Z"},"repeating":{"period":null,"pattern":{"time":"22:44:13+01:00","yearly":{"day":4,"month":"JAN"},"definedPatternNumber":0}}}
277
+ {"period":null,"pattern":{"time":"22:44:13+01:00","yearly":{"day":4,"month":"JAN"},"definedPatternNumber":1}}
239
278
  """
240
279
 
241
280
  Scenario: Execute periodic operation every year without day and fail
242
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
281
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
282
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
243
283
  And the notes by ""
244
284
  And the timeout by 120000
245
285
  And the ackTimeout by 0
246
286
  And the retries by 0
247
287
  And the retriesDelay by 0
248
- And parameter "admsts" by "inventado"
249
- And the job timeout by 5 minutes
288
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
289
+ And the job timeout by 300 seconds
250
290
  And execute every year at "2020-02-10T21:44:13Z" on month "FEB"
251
291
  And append entities by:
252
- | execute_periodic_device |
292
+ | execute_periodic_device_C |
253
293
  When I build it
254
294
  And I execute it
255
295
  Then response code should be: 201
@@ -261,17 +301,18 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
261
301
 
262
302
 
263
303
  Scenario: Execute periodic operation every year without month and fail
264
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
304
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
305
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
265
306
  And the notes by ""
266
307
  And the timeout by 120000
267
308
  And the ackTimeout by 0
268
309
  And the retries by 0
269
310
  And the retriesDelay by 0
270
- And parameter "admsts" by "inventado"
271
- And the job timeout by 5 minutes
311
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
312
+ And the job timeout by 300 seconds
272
313
  And execute every year at "2020-03-10T21:44:13Z" at day 5
273
314
  And append entities by:
274
- | execute_periodic_device |
315
+ | execute_periodic_device_C |
275
316
  When I build it
276
317
  And I execute it
277
318
  Then response code should be: 201
@@ -283,53 +324,63 @@ Feature: Execute ADMINISTRATIVE_STATUS_CHANGE periodic operation
283
324
 
284
325
 
285
326
  Scenario: Execute periodic operation every year without start and fail
286
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
327
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
328
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
287
329
  And the notes by ""
288
330
  And the timeout by 120000
289
331
  And the ackTimeout by 0
290
332
  And the retries by 0
291
333
  And the retriesDelay by 0
292
- And parameter "admsts" by "inventado"
293
- And the job timeout by 5 minutes
334
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
335
+ And the job timeout by 300 seconds
294
336
  When execute every year at day 29 on month "MAR"
295
337
  Then throws an error equal to "Parameter date must be typeof Date"
296
338
 
297
339
  Scenario: Execute periodic operation every year without start and month fail
298
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
340
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
341
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
299
342
  And the notes by ""
300
343
  And the timeout by 120000
301
344
  And the ackTimeout by 0
302
345
  And the retries by 0
303
346
  And the retriesDelay by 0
304
- And parameter "admsts" by "inventado"
305
- And the job timeout by 5 minutes
347
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
348
+ And the job timeout by 300 seconds
306
349
  When execute every year at day 18
307
350
  Then throws an error equal to "Parameter date must be typeof Date"
308
351
 
309
352
  Scenario: Execute periodic operation every year without start and day fail
310
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
353
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
354
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
311
355
  And the notes by ""
312
356
  And the timeout by 120000
313
357
  And the ackTimeout by 0
314
358
  And the retries by 0
315
359
  And the retriesDelay by 0
316
- And parameter "admsts" by "inventado"
317
- And the job timeout by 5 minutes
360
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
361
+ And the job timeout by 300 seconds
318
362
  When execute every year on month "APR"
319
363
  Then throws an error equal to "Parameter date must be typeof Date"
320
364
 
321
365
 
322
- Scenario: I want to delete the entity
323
- Given the entity of type "devices builder" with "base_organization"
366
+ Scenario: Postcondition - I want to delete the entity
367
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
368
+ Given the entity of type "devices builder" with "execute_periodic_organization_10"
324
369
  And I get allowed Datastreams fields
325
370
  And I can found "provision.device.identifier" as datastream name
326
371
  When I try to define the entity with...
327
372
  | datastream | typeFunction | value | parent |
328
- | provision.device.identifier | simple | execute_periodic_device | |
373
+ | provision.device.identifier | simple | execute_periodic_device_C | |
329
374
  And I delete it
330
375
  Then response code should be: 200
331
376
 
332
- Scenario: Deleting an organization
377
+ Scenario: Postcondition - Deleting an user
378
+ Given an ogapi "users builder" util
379
+ Then I want to delete a "user"
380
+ And the "email" "ogux_ogapi@amplia.com"
381
+ Then I delete it
382
+
383
+ Scenario: Postcondition - Deleting an organization
333
384
  Given an ogapi "organizations builder" util
334
385
  Then I want to delete an "organization"
335
386
  And the "name" "execute_periodic_organization_10"
@@ -14,7 +14,7 @@ Feature: Find an operation
14
14
  Background:
15
15
  Given an apikey user by "require-real-apikey"
16
16
 
17
- Scenario: Creating an organization to use in create device
17
+ Scenario: Precondition - Creating an organization to use in create device
18
18
  Given an ogapi "organizations builder" util
19
19
  Then I want to create an "organization"
20
20
  And the "name" "find_execution_organization_10"
@@ -28,7 +28,36 @@ Feature: Find an operation
28
28
  Then I create it
29
29
  And response code should be: 201
30
30
 
31
- Scenario: I want to create an entity
31
+ Scenario: Precondition - Create and delete an user that does not exist
32
+ And an ogapi "users builder" util
33
+ And I want to create a "user"
34
+ And the "email" "ogux_ogapi@amplia.com"
35
+ And the "password" "Nvoiqewvouoiu32j@#!!"
36
+ And the "workgroup" "find_execution_organization_10"
37
+ And the "domain" "find_execution_organization_10"
38
+ And the "profile" "admin_domain"
39
+ And the "countryCode" "ES"
40
+ And the "langCode" "en"
41
+ And the "name" "test name"
42
+ And the "surname" "test surname"
43
+ And the "description" "user description"
44
+ Then I delete it
45
+ And I create it
46
+ Then response code should be: 201
47
+
48
+ Scenario: Precondition - I want to create an operation Type
49
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
50
+ Given an ogapi "operation type" util with "find_execution_organization_10"
51
+ Then I want to create an "operation type"
52
+ And the "name" "ADMINISTRATIVE_STATUS_CHANGE_TEST"
53
+ And the "title" "Administrative status change test"
54
+ And the "description" "Allows to change the administrative status of an entity"
55
+ And the "fromCatalog" "ADMINISTRATIVE_STATUS_CHANGE"
56
+ Then I create it
57
+ And response code should be: 201
58
+
59
+ Scenario: Precondition - I want to create an entity
60
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
32
61
  Given the entity of type "devices builder" with "find_execution_organization_10"
33
62
  Then I get allowed Datastreams fields
34
63
  And I can found "provision.device.identifier" as datastream name
@@ -37,7 +66,7 @@ Feature: Find an operation
37
66
  | provision.administration.channel | simple | default_channel | |
38
67
  | provision.administration.organization | simple | find_execution_organization_10 | |
39
68
  | provision.administration.serviceGroup | simple | emptyServiceGroup | |
40
- | provision.device.identifier | simple | find_execution_device | |
69
+ | provision.device.identifier | simple | find_execution_device_a | |
41
70
  | provision.device.operationalStatus | simple | NORMAL | |
42
71
  | provision.device.administrativeState | simple | ACTIVE | |
43
72
 
@@ -46,26 +75,28 @@ Feature: Find an operation
46
75
 
47
76
 
48
77
  Scenario: Execute operation with default values and find operation
49
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
78
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
79
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
50
80
  And the notes by ""
51
81
  And the timeout by 120000
52
82
  And the ackTimeout by 0
53
83
  And the retries by 0
54
84
  And the retriesDelay by 0
55
- And parameter "admsts" by "inventado"
56
- And the job timeout by 5 minutes
85
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
86
+ And the job timeout by 300 seconds
57
87
  And execute immediately
58
88
  And append entities by:
59
- | find_execution_device |
89
+ | find_execution_device_a |
60
90
  When I build it
61
91
  And I execute it
62
92
  Then response code should be: 201
63
93
  And an ogapi "operation finder" util
64
94
  And I want to read a "operation"
65
95
  When I try to find by operation's id
66
- Then I can see into the result an "operation type" as "ADMINISTRATIVE_STATUS_CHANGE"
96
+ Then I can see into the result an "operation type" as "ADMINISTRATIVE_STATUS_CHANGE_TEST"
67
97
 
68
98
  Scenario: Find a operation that not exists
99
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
69
100
  Given an ogapi "operation finder" util
70
101
  And I want to read a "operation"
71
102
  When I try to find by...
@@ -73,17 +104,24 @@ Feature: Find an operation
73
104
  | id | not_exists |
74
105
  Then response code should be: 200
75
106
 
76
- Scenario: I want to delete the entity
107
+ Scenario: Postcondition - I want to delete the entity
108
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
77
109
  Given the entity of type "devices builder" with "find_execution_organization_10"
78
110
  And I get allowed Datastreams fields
79
111
  And I can found "provision.device.identifier" as datastream name
80
112
  When I try to define the entity with...
81
113
  | datastream | typeFunction | value | parent |
82
- | provision.device.identifier | simple | find_execution_device | |
114
+ | provision.device.identifier | simple | find_execution_device_a | |
83
115
  And I delete it
84
116
  Then response code should be: 200
85
117
 
86
- Scenario: Deleting an organization
118
+ Scenario: Postcondition - Deleting an user
119
+ Given an ogapi "users builder" util
120
+ Then I want to delete a "user"
121
+ And the "email" "ogux_ogapi@amplia.com"
122
+ Then I delete it
123
+
124
+ Scenario: Postcondition - Deleting an organization
87
125
  Given an ogapi "organizations builder" util
88
126
  Then I want to delete an "organization"
89
127
  And the "name" "find_execution_organization_10"
@@ -27,7 +27,36 @@ Feature: Find a executions of an operation
27
27
  Then I create it
28
28
  And response code should be: 201
29
29
 
30
- Scenario: I want to create an entity
30
+ Scenario: Precondition - Create and delete an user that does not exist
31
+ And an ogapi "users builder" util
32
+ And I want to create a "user"
33
+ And the "email" "ogux_ogapi@amplia.com"
34
+ And the "password" "Nvoiqewvouoiu32j@#!!"
35
+ And the "workgroup" "find_find_executions_organization_10"
36
+ And the "domain" "find_find_executions_organization_10"
37
+ And the "profile" "admin_domain"
38
+ And the "countryCode" "ES"
39
+ And the "langCode" "en"
40
+ And the "name" "test name"
41
+ And the "surname" "test surname"
42
+ And the "description" "user description"
43
+ Then I delete it
44
+ And I create it
45
+ Then response code should be: 201
46
+
47
+ Scenario: Precondition - I want to create an operation Type
48
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
49
+ Given an ogapi "operation type" util with "find_find_executions_organization_10"
50
+ Then I want to create an "operation type"
51
+ And the "name" "ADMINISTRATIVE_STATUS_CHANGE_TEST"
52
+ And the "title" "Administrative status change test"
53
+ And the "description" "Allows to change the administrative status of an entity"
54
+ And the "fromCatalog" "ADMINISTRATIVE_STATUS_CHANGE"
55
+ Then I create it
56
+ And response code should be: 201
57
+
58
+ Scenario: Precondition - I want to create an entity
59
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
31
60
  Given the entity of type "devices builder" with "find_find_executions_organization_10"
32
61
  And I get allowed Datastreams fields
33
62
  And I can found "provision.device.identifier" as datastream name
@@ -44,14 +73,15 @@ Feature: Find a executions of an operation
44
73
  And response code should be: 201
45
74
 
46
75
  Scenario: Execute operation with default values and find its executions
47
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
76
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
77
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
48
78
  And the notes by ""
49
79
  And the timeout by 120000
50
80
  And the ackTimeout by 0
51
81
  And the retries by 0
52
82
  And the retriesDelay by 0
53
- And parameter "admsts" by "inventado"
54
- And the job timeout by 5 minutes
83
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
84
+ And the job timeout by 300 seconds
55
85
  And execute immediately
56
86
  And append entities by:
57
87
  | find_executions_device |
@@ -61,9 +91,10 @@ Feature: Find a executions of an operation
61
91
  And an ogapi "operation finder" util
62
92
  And I want to read a "executions"
63
93
  When I try to find by operation's id
64
- Then I can see into the result an "execution type" as "ADMINISTRATIVE_STATUS_CHANGE"
94
+ Then I can see into the result an "execution type" as "ADMINISTRATIVE_STATUS_CHANGE_TEST"
65
95
 
66
96
  Scenario: Find a executions of an operation that not exists
97
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
67
98
  Given an ogapi "operation finder" util
68
99
  And I want to read a "executions"
69
100
  When I try to find by...
@@ -72,14 +103,15 @@ Feature: Find a executions of an operation
72
103
  Then response code should be: 404
73
104
 
74
105
  Scenario: Execute operation with default values and find its executions with limit
75
- Given the operation by "ADMINISTRATIVE_STATUS_CHANGE"
106
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
107
+ Given the operation by "ADMINISTRATIVE_STATUS_CHANGE_TEST"
76
108
  And the notes by ""
77
109
  And the timeout by 120000
78
110
  And the ackTimeout by 0
79
111
  And the retries by 0
80
112
  And the retriesDelay by 0
81
- And parameter "admsts" by "inventado"
82
- And the job timeout by 5 minutes
113
+ And the parameters "{ \"admsts\" : \"ACTIVE\" }"
114
+ And the job timeout by 300 seconds
83
115
  And execute immediately
84
116
  And append entities by:
85
117
  | find_executions_device |
@@ -89,9 +121,10 @@ Feature: Find a executions of an operation
89
121
  And an ogapi "operation finder" util
90
122
  And I want to read a "executions" and the start limit by "1" and size limit by "1"
91
123
  When I try to find by operation's id
92
- Then I can see into the result an "execution type" as "ADMINISTRATIVE_STATUS_CHANGE"
124
+ Then I can see into the result an "execution type" as "ADMINISTRATIVE_STATUS_CHANGE_TEST"
93
125
 
94
- Scenario: I want to delete the entity
126
+ Scenario: Postcondition - I want to delete the entity
127
+ Given an email "ogux_ogapi@amplia.com" and password "Nvoiqewvouoiu32j@#!!" the user logs in
95
128
  Given the entity of type "devices builder" with "find_find_executions_organization_10"
96
129
  And I get allowed Datastreams fields
97
130
  And I can found "provision.device.identifier" as datastream name
@@ -101,7 +134,14 @@ Feature: Find a executions of an operation
101
134
  And I delete it
102
135
  Then response code should be: 200
103
136
 
104
- Scenario: Deleting an organization
137
+ Scenario: Postcondition - Deleting an user
138
+ Given an apikey user by "1e0a6fa7-d770-4072-ab4e-f98581522a65"
139
+ Given an ogapi "users builder" util
140
+ Then I want to delete a "user"
141
+ And the "email" "ogux_ogapi@amplia.com"
142
+ Then I delete it
143
+
144
+ Scenario: Postcondition - Deleting an organization
105
145
  Given an ogapi "organizations builder" util
106
146
  Then I want to delete an "organization"
107
147
  And the "name" "find_find_executions_organization_10"