Commit a53667fe authored by Łukasz Nowak's avatar Łukasz Nowak

Check Business Process definitions.

Nothing shall be delivered in this moment. Only top level Simulation Movements
shall be buildable.
parent caf2ff4d
master alain-message amarisoft boot/offline cliff-cleanup console cygwin-link-local feat/node-secrets feat/nxdbom feat/openapi feat/slapos-computer-partitions-capabilities-wip feat/standalone-service feat_open_order feature/cgroups feature/format-crumbled feature/manager-cpuset fix/request-download-speed fix/slapos-ansible fix/verify fix/write-history for_testrunner_1 hostingwebsite json-api json-api-2022 json-api-slapgrid lazy_simulation_causality lxc master-dev message-box payzen-fixup proxy slapjs slapos-override-env slapproxy-connection-parameter urlJS zope4py3 1.15.0 1.14.3 1.14.2 1.14.1 1.14.0 1.13.0 1.12.0 1.11.0 1.10.8 1.10.7 1.10.6 1.10.5 1.10.4 1.10.3 1.10.2 1.10.1 1.10.0 1.9.3 1.9.2 1.9.1 1.9.0 1.8.6 1.8.5 1.8.4 1.8.3 1.8.2 1.8.1 1.8.0 1.7.13 1.7.12 1.7.11 1.7.10 1.7.9 1.7.8 1.7.7 1.7.6 1.7.5 1.7.4 1.7.3 1.7.2 1.7.1 1.7.0 1.6.19 1.6.18 1.6.17 1.6.16 1.6.15 1.6.14 1.6.13 1.6.12 1.6.11 1.6.10 1.6.9 1.6.8 1.6.7 1.6.6 1.6.5 1.6.4 1.6.3 1.6.2 1.6.1 1.6.0 1.5.12 1.5.11 1.5.10 1.5.9 1.5.8 1.5.7 1.5.6 1.5.5 1.5.4 1.5.3 1.5.2 1.5.1 1.5.0 1.4.28 1.4.27 1.4.26 1.4.25 1.4.24 1.4.23 1.4.22 1.4.21 1.4.20 1.4.19 1.4.17 1.4.16 1.4.15 1.4.14 1.4.12 1.4.11 1.4.10 1.4.9 1.4.8 1.4.7 1.4.6 1.4.5 1.4.4 1.4.3 1.4.2 1.4.1 1.4.0 1.3.18 1.3.17 1.3.16 1.3.15 1.3.14 1.3.13 1.3.12 1.3.11 1.3.10 1.3.9 1.3.8 1.3.7 1.3.6.3 1.3.6.2 1.3.6.1 1.3.6 1.3.5 1.3.4 1.3.3 1.3.2 1.3.1 1.3.0 1.2.4.1 1.2.4 1.2.3.1 1.2.3 1.2.2 1.2.1 1.2.0 1.1.3 1.1.2 1.1.1 1.1.0 1.0.5 1.0.4 1.0.3 1.0.2 1.0.1 1.0.0 1.0.0rc6 1.0.0rc5 1.0.0rc4 1.0.0rc3 1.0.0-rc1 0.35.1 0.34 0.33.1 0.33 0.32.3 0.32.2 0.32 0.31.2 0.31.1 0.31 0.30 0.29 0.28.9 0.28.8 0.28.7 0.28.6 0.28.5 0.28.4 0.28.3 0.28.2 0.28.1 0.28 0.27 0.26.2 0.26.1 0.26 0.25 0.24 0.23 0.22 v1.8.1 master-20240326 master-20240326+p1 master-20180917 jquerymobile.noanimation
No related merge requests found
......@@ -143,6 +143,11 @@ class TestVifibOpenOrderSimulation(TestVifibSlapWebServiceMixin):
self.assertEqual(expected_start_date, simulation_movement.getStartDate())
self.assertEqual(expected_stop_date, simulation_movement.getStopDate())
# not delivered yet
self.assertEqual(None, simulation_movement.getDelivery())
# packing list shall be buildable
self.assertTrue(simulation_movement.isBuildable())
# fetch invoice level simulation
applied_rule_invoice_list = \
simulation_movement.contentValues(portal_type="Applied Rule")
......@@ -157,6 +162,11 @@ class TestVifibOpenOrderSimulation(TestVifibSlapWebServiceMixin):
simulation_movement_invoice_list[0].getObject()
self.assertNotEquals(None, simulation_movement_invoice)
# not delivered yet
self.assertEqual(None, simulation_movement_invoice.getDelivery())
# invoice shall be not yet buildable
self.assertFalse(False, simulation_movement_invoice.isBuildable())
# check property of invoice simulation
self.assertEquals(1.0,
simulation_movement_invoice.getQuantity())
......@@ -213,6 +223,10 @@ class TestVifibOpenOrderSimulation(TestVifibSlapWebServiceMixin):
simulation_movement_invoice_transaction_debit = None
for simulation_movement_invoice_transaction in \
simulation_movement_invoice_transaction_list:
# not delivered nor buildable
self.assertEqual(None, simulation_movement_invoice_transaction\
.getDelivery())
self.assertFalse(simulation_movement_invoice_transaction.isBuildable())
if "business_process_module/vifib_sale_business_process/account_credit_path" \
in simulation_movement_invoice_transaction.getCausalityList():
simulation_movement_invoice_transaction_credit = \
......@@ -222,7 +236,17 @@ class TestVifibOpenOrderSimulation(TestVifibSlapWebServiceMixin):
simulation_movement_invoice_transaction_debit = \
simulation_movement_invoice_transaction.getObject()
self.assertNotEquals(None, simulation_movement_invoice_transaction_credit)
# not delivered nor buildable
self.assertEqual(None, simulation_movement_invoice_transaction_credit\
.getDelivery())
self.assertFalse(simulation_movement_invoice_transaction_credit\
.isBuildable())
self.assertNotEquals(None, simulation_movement_invoice_transaction_debit)
# not delivered nor buildable
self.assertEqual(None, simulation_movement_invoice_transaction_debit\
.getDelivery())
self.assertFalse(simulation_movement_invoice_transaction_debit\
.isBuildable())
# check property of invoice transaction simulation
self.assertEquals(-1.0,
......@@ -309,7 +333,17 @@ class TestVifibOpenOrderSimulation(TestVifibSlapWebServiceMixin):
simulation_movement_credit_payment_debit = \
simulation_movement_credit_payment.getObject()
self.assertNotEquals(None, simulation_movement_credit_payment_credit)
# not delivered nor buildable
self.assertEqual(None, simulation_movement_credit_payment_credit\
.getDelivery())
self.assertFalse(simulation_movement_credit_payment_credit\
.isBuildable())
self.assertNotEquals(None, simulation_movement_credit_payment_debit)
# not delivered nor buildable
self.assertEqual(None, simulation_movement_credit_payment_debit\
.getDelivery())
self.assertFalse(simulation_movement_credit_payment_debit\
.isBuildable())
# check payment level of simulation
self.assertEquals(-1.0,
......
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