def test_valueConstraintType_picklist_parse_case_insensitive(): """Value constraint types are case-insensitive.""" st = TAPStatementTemplate() st.propertyID = "dcterms:creator" st.valueConstraintType = "PICKLIST" st.valueConstraint = "one two three" # extra whitespace st._valueConstraintType_picklist_parse(config_dict) assert st.valueConstraint == ["one", "two", "three"]
def test_valueConstraintType_picklist_parse(): """If valueConstraintType picklist, valueConstraint parsed on whitespace.""" st = TAPStatementTemplate() st.propertyID = "dcterms:creator" st.valueConstraintType = "picklist" st.valueConstraint = "one two three" st._valueConstraintType_picklist_parse(config_dict) assert st.valueConstraint == ["one", "two", "three"]