Skip to content

Commit 186d80c

Browse files
committed
[validation] Change object name missing msg
1 parent 199a649 commit 186d80c

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

odml/validation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,7 @@ def object_name_readable(obj):
409409
validation_id = ValidationID.object_name_readable
410410

411411
if obj.name == obj.id:
412-
yield ValidationError(obj, "Name should be readable", LABEL_WARNING, validation_id)
412+
yield ValidationError(obj, "Name not assigned", LABEL_WARNING, validation_id)
413413

414414

415415
Validation.register_handler('section', object_name_readable)

test/test_validation.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,7 @@ def test_section_name_readable(self):
276276
sec = odml.Section("sec", parent=doc)
277277
sec.name = sec.id
278278
res = Validate(doc)
279-
self.assertError(res, "Name should be readable")
279+
self.assertError(res, "Name not assigned")
280280

281281
def test_property_name_readable(self):
282282
"""
@@ -287,7 +287,7 @@ def test_property_name_readable(self):
287287
prop = odml.Property("prop", parent=sec)
288288
prop.name = prop.id
289289
res = Validate(doc)
290-
self.assertError(res, "Name should be readable")
290+
self.assertError(res, "Name not assigned")
291291

292292
def test_standalone_section(self):
293293
"""

0 commit comments

Comments
 (0)