Commit 5165f145 authored by Xiaowu Zhang's avatar Xiaowu Zhang

erp5_configurator_standard: enable career constraint

parent ec55733a
......@@ -29,3 +29,7 @@ configuration_save.addConfigurationItem("Portal Type Configurator Item",
configuration_save.addConfigurationItem("Portal Type Configurator Item",
target_portal_type='Currency',
add_propertysheet_list=('CurrencyConstraint',))
configuration_save.addConfigurationItem("Portal Type Configurator Item",
target_portal_type='Career',
add_propertysheet_list=('CareerConstraint',))
......@@ -202,6 +202,7 @@ class StandardConfigurationMixin(TestLiveConfiguratorWorkflowMixin):
"""
Check if after the configuration the Person objects are validated.
The Assignments must be opened and valid.
Employee number is defined
"""
business_configuration = sequence.get("business_configuration")
person_list = self.getBusinessConfigurationObjectList(business_configuration, 'Person')
......@@ -217,6 +218,14 @@ class StandardConfigurationMixin(TestLiveConfiguratorWorkflowMixin):
self.assertNotEquals(None, assignment.getStopDate())
self.assertEqual(assignment.getGroup(), "my_group")
assignment.Base_checkConsistency()
current_career = person.getDefaultCareerValue()
employee_number = current_career.getReference()
self.assertNotEqual(employee_number, None)
self.assertEqual(len(current_career.checkConsistency()), 0)
current_career.edit(reference='')
self.assertEqual(len(current_career.checkConsistency()), 1)
current_career.edit(reference=employee_number)
def stepCheckPersonInformationList(self, sequence=None, sequence_list=None, **kw):
"""
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment