Commit 4b863030 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

simulation hierarchy is different if it begins with delivery.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@33470 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 9ec094c6
...@@ -391,10 +391,13 @@ class TestBPMEvaluationMixin(TestBPMMixin): ...@@ -391,10 +391,13 @@ class TestBPMEvaluationMixin(TestBPMMixin):
# root rule is order or delivery - so below each movement invoicing one # root rule is order or delivery - so below each movement invoicing one
# is expected # is expected
self.assertEquals(len(root_simulation_movement.contentValues()), 1) self.assertEquals(len(root_simulation_movement.contentValues()), 1)
if self.root_rule_portal_type == 'Order Root Simulation Rule':
delivery_rule = root_simulation_movement.contentValues()[0] delivery_rule = root_simulation_movement.contentValues()[0]
delivery_simulation_movement_list = delivery_rule.contentValues() delivery_simulation_movement_list = delivery_rule.contentValues()
self.assertEqual(1, len(delivery_simulation_movement_list)) self.assertEqual(1, len(delivery_simulation_movement_list))
delivery_simulation_movement = delivery_simulation_movement_list[0] delivery_simulation_movement = delivery_simulation_movement_list[0]
else:
delivery_simulation_movement = root_simulation_movement
for bpm_invoicing_rule in delivery_simulation_movement.contentValues(): for bpm_invoicing_rule in delivery_simulation_movement.contentValues():
self.assertEqual(bpm_invoicing_rule.getPortalType(), 'Applied Rule') self.assertEqual(bpm_invoicing_rule.getPortalType(), 'Applied Rule')
self.assertEqual(bpm_invoicing_rule.getSpecialiseValue() \ self.assertEqual(bpm_invoicing_rule.getSpecialiseValue() \
......
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