These attribute values should be validated as part of the config validation phase.
Design
config_validator.py
Add a validate_dummy_fields method to config_validator.py and call it inside the validate method as part of the errors list. This method should return a list of error messages for any invalid fields in the dummy_fields section each domain object.
config_validator_test.py
A test_dummy_field_failure method should be added to config_validator_test.py to ensure invalid values are caught.
Documentation Changes
Add docstring to validate_dummy_fields and test_dummy_field_failure
Test Evidence
The newly written test should pass as expected, and running python src/app.py with invalid dummy field values in the config should display the expected error message(s).
Issue Description
Dummy fields are currently generated as specified in
config.json
:These attribute values should be validated as part of the config validation phase.
Design
config_validator.py
Add a
validate_dummy_fields
method toconfig_validator.py
and call it inside thevalidate
method as part of theerrors
list. This method should return a list of error messages for any invalid fields in thedummy_fields
section each domain object.config_validator_test.py
A
test_dummy_field_failure
method should be added toconfig_validator_test.py
to ensure invalid values are caught.Documentation Changes
Add docstring to
validate_dummy_fields
andtest_dummy_field_failure
Test Evidence
The newly written test should pass as expected, and running
python src/app.py
with invalid dummy field values in the config should display the expected error message(s).Validation in Develop
N/A