diff --git a/product/ERP5/tests/testERP5Simulation.py b/product/ERP5/tests/testERP5Simulation.py index cae1bc30fb13a76a8fc49206204d21902fafe790..8127750a4c1df42444501730b24d6aff8f2bf4a0 100644 --- a/product/ERP5/tests/testERP5Simulation.py +++ b/product/ERP5/tests/testERP5Simulation.py @@ -422,6 +422,21 @@ class TestERP5SimulationPackingList(TestERP5SimulationMixin, TestPackingList): [x.getOrder() for x in \ line.getDeliveryRelatedValueList()]) + def stepUnifyDestinationWithDecision(self,sequence=None, sequence_list=None, **kw): + """ + Check if simulation movement are disconnected + """ + packing_list = sequence.get('packing_list') + solver_tool = self.portal.portal_solvers + solver_process = solver_tool.newSolverProcess(packing_list) + for destination_solver_decision in filter( + lambda x:x.getCausalityValue().getTestedProperty()=='destination', + solver_process.contentValues()): + # use Destination Replacement Solver. + destination_solver_decision.setSolverValue(self.portal.portal_types['Destination Replacement Solver']) + solver_process.buildTargetSolverList() + solver_process.solve() + def test_suite(): suite = unittest.TestSuite() suite.addTest(unittest.makeSuite(TestERP5Simulation))