diff --git a/product/ERP5Type/tests/testERP5Type.py b/product/ERP5Type/tests/testERP5Type.py index 2ead354a09f9ceba24d4a55b6d2f71fa451a86fe..aae135a4a4bf615376d97184a072059f8ea452a8 100644 --- a/product/ERP5Type/tests/testERP5Type.py +++ b/product/ERP5Type/tests/testERP5Type.py @@ -3050,6 +3050,17 @@ class TestERP5Type(PropertySheetTestCase, LogInterceptor): if len(index_list): portal_actions.deleteActions(selections=index_list) + def test_propertyMap_unique_properties(self): + portal = self.getPortalObject() + person = portal.person_module.newContent(portal_type='Person') + property_id_dict = dict() + non_unique_property_id_list = [] + for property_id in [p['id'] for p in person.propertyMap()]: + if property_id in property_id_dict: + non_unique_property_id_list.append(property_id) + property_id_dict[property_id] = 1 + self.assertEqual([], non_unique_property_id_list) + class TestAccessControl(ERP5TypeTestCase): # Isolate test in a dedicaced class in order not to break other tests # when this one fails.