Skip to content

Commit 206b274

Browse files
committed
[test_validation.py] Add Test for Property Name Readability
1 parent 13a51c8 commit 206b274

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

test/test_validation.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,17 @@ def test_section_name_readable(self):
139139
res = validate(doc)
140140
self.assertError(res, "Name should be readable")
141141

142+
def test_property_name_readable(self):
143+
"""
144+
Test if property name is not uuid and thus more readable.
145+
"""
146+
doc = odml.Document()
147+
sec = odml.Section("sec", parent=doc)
148+
prop = odml.Property("prop", parent=sec)
149+
prop.name = prop.id
150+
res = validate(doc)
151+
self.assertError(res, "Name should be readable")
152+
142153
def test_standalone_section(self):
143154
"""
144155
Test if standalone section does not return errors if required attributes are correct.

0 commit comments

Comments
 (0)