Skip to content

Commit d632535

Browse files
committed
Check required field provided
1 parent debcf51 commit d632535

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

tests/dataconverter/test_helpers.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,14 @@ def fixture_filled_test_data(template, tmp_path):
356356
TEMPLATE, "/ENTRY[my_entry]/OPTIONAL_group[my_group]/optional_field", 1
357357
),
358358
(""),
359-
id="required-field-not-provided-in-optional-group",
359+
id="required-field-not-provided-in-variadic-optional-group",
360+
),
361+
pytest.param(
362+
alter_dict(
363+
TEMPLATE, "/ENTRY[my_entry]/OPTIONAL_group[my_group]/required_field", 1
364+
),
365+
(""),
366+
id="required-field-provided-in-variadic-optional-group",
360367
),
361368
pytest.param(
362369
alter_dict(
@@ -422,6 +429,7 @@ def test_validate_data_dict(
422429
"int-instead-of-chars",
423430
"link-dict-instead-of-bool",
424431
"opt-group-completely-removed",
432+
"required-field-provided-in-variadic-optional-group",
425433
):
426434
helpers.validate_data_dict(template, data_dict, nxdl_root)
427435
# Missing required fields caught by logger with warning

0 commit comments

Comments
 (0)