Browse Source

Merge "text_list attributes could be empty"

Jenkins 2 years ago
parent
commit
8253c39562

+ 3
- 3
nailgun/nailgun/api/v1/validators/json_schema/base_types.py View File

@@ -282,16 +282,16 @@ ALLOWED_VALUES_SCHEMA = {
282 282
 MULTIPLE_TEXT_FIELDS_SCHEMA = {
283 283
     'value': {
284 284
         'type': 'array',
285
-        'minItems': 1,
285
+        'minItems': 0,
286 286
         'items': {'type': 'string'},
287 287
     },
288 288
     'min': {
289 289
         'type': 'integer',
290
-        'minimum': 1,
290
+        'minimum': 0,
291 291
     },
292 292
     'max': {
293 293
         'type': 'integer',
294
-        'minimum': 1,
294
+        'minimum': 0,
295 295
     }
296 296
 }
297 297
 

+ 1
- 0
nailgun/nailgun/fixtures/openstack.yaml View File

@@ -1305,6 +1305,7 @@
1305 1305
             description: "List of upstream DNS servers"
1306 1306
             weight: 10
1307 1307
             type: "text_list"
1308
+            min: 0
1308 1309
             max: 3
1309 1310
             regex:
1310 1311
               source: &ipv4_regex '^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$'

Loading…
Cancel
Save