Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Lu Xu
erp5
Commits
73a1db3d
Commit
73a1db3d
authored
Oct 30, 2017
by
Cédric Le Ninivin
Committed by
Cédric Le Ninivin
Nov 16, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
testMRP: Update business process to use transformation_sourcing_internal_packing_list_builder
parent
7df8001b
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
12 deletions
+19
-12
product/ERP5/tests/testMRP.py
product/ERP5/tests/testMRP.py
+19
-12
No files found.
product/ERP5/tests/testMRP.py
View file @
73a1db3d
...
@@ -168,8 +168,10 @@ class TestMRPMixin(TestBPMMixin):
...
@@ -168,8 +168,10 @@ class TestMRPMixin(TestBPMMixin):
Terms
Terms
=====
=====
PPL : Production Packing List
PPL : Production Packing List
PR
: Manufacturing Execution
ME
: Manufacturing Execution
PO : Production Order
PO : Production Order
MO : Manufacturing Order
IPL : Internal Packing List
Context
Context
=======
=======
...
@@ -198,14 +200,14 @@ class TestMRPMixin(TestBPMMixin):
...
@@ -198,14 +200,14 @@ class TestMRPMixin(TestBPMMixin):
=======================
=======================
order order p0 s0 p1 deliver
order order p0 s0 p1 deliver
------- S0 ----- S1 ---- S2 ---- S3 ---- S4 -------- S5
------- S0 ----- S1 ---- S2 ---- S3 ---- S4 -------- S5
PO MO ME1
PPL1 ME2 PPL2
PO MO ME1
IPL ME2 PPL
Simulation Tree
Simulation Tree
===============
===============
* PO / new_order_root_simulation_rule
* PO / new_order_root_simulation_rule
* Production Order Line
* Production Order Line
* default_delivering_rule
* default_delivering_rule
* PPL
2
* PPL
* default_production_rule
* default_production_rule
* MO
* MO
* default_transformation_rule
* default_transformation_rule
...
@@ -214,7 +216,7 @@ class TestMRPMixin(TestBPMMixin):
...
@@ -214,7 +216,7 @@ class TestMRPMixin(TestBPMMixin):
* output ME1 - partial product
* output ME1 - partial product
* input ME2 - partial product
* input ME2 - partial product
* default_transformation_source_rule
* default_transformation_source_rule
*
PPL1
*
IPL
* input ME2
* input ME2
* default_transformation_source_rule
* default_transformation_source_rule
* input ME2
* input ME2
...
@@ -225,12 +227,13 @@ class TestMRPMixin(TestBPMMixin):
...
@@ -225,12 +227,13 @@ class TestMRPMixin(TestBPMMixin):
production_packing_list_builder
=
'portal_deliveries/production_packing_list_builder'
production_packing_list_builder
=
'portal_deliveries/production_packing_list_builder'
manufacturing_execution_builder
=
'portal_deliveries/manufacturing_execution_builder'
manufacturing_execution_builder
=
'portal_deliveries/manufacturing_execution_builder'
manufacturing_order_builder
=
'portal_deliveries/manufacturing_order_builder'
manufacturing_order_builder
=
'portal_deliveries/manufacturing_order_builder'
sourcing_builder
=
'portal_deliveries/transformation_sourcing_internal_packing_list_builder'
completed
=
'delivered'
,
'started'
,
'stopped'
completed
=
'delivered'
,
'started'
,
'stopped'
phase_list
=
[
phase_list
=
[
(
'default/order'
,
None
,
(
'confirmed'
,)),
(
'default/order'
,
None
,
(
'confirmed'
,)),
(
'manufacturing/order'
,
manufacturing_order_builder
,
(
'confirmed'
,)),
(
'manufacturing/order'
,
manufacturing_order_builder
,
(
'confirmed'
,)),
(
'mrp/p0'
,
manufacturing_execution_builder
,
completed
),
(
'mrp/p0'
,
manufacturing_execution_builder
,
completed
),
(
'mrp/s0'
,
production_packing_list
_builder
,
completed
),
(
'mrp/s0'
,
sourcing
_builder
,
completed
),
(
'mrp/p1'
,
manufacturing_execution_builder
,
completed
),
(
'mrp/p1'
,
manufacturing_execution_builder
,
completed
),
(
'default/delivery'
,
production_packing_list_builder
,
completed
)
(
'default/delivery'
,
production_packing_list_builder
,
completed
)
]
]
...
@@ -283,6 +286,10 @@ class TestMRPImplementation(TestMRPMixin):
...
@@ -283,6 +286,10 @@ class TestMRPImplementation(TestMRPMixin):
self
.
tic
()
self
.
tic
()
def
testSimpleOrder
(
self
):
def
testSimpleOrder
(
self
):
"""
We test the process implemented in 'createBusinessProcess1' is
correctly followed
"""
self
.
createMRPOrder
()
self
.
createMRPOrder
()
order
=
self
.
order
order
=
self
.
order
...
@@ -353,9 +360,9 @@ class TestMRPImplementation(TestMRPMixin):
...
@@ -353,9 +360,9 @@ class TestMRPImplementation(TestMRPMixin):
variation
=
'industrial_phase/trade_phase/mrp/p0'
variation
=
'industrial_phase/trade_phase/mrp/p0'
self
.
checkStock
(
resource
,
(
self
.
workshop2
,
variation
,
10
))
self
.
checkStock
(
resource
,
(
self
.
workshop2
,
variation
,
10
))
ppl1
,
=
getRelatedDeliveryList
(
"Production
Packing List"
)
ipl
,
=
getRelatedDeliveryList
(
"Internal
Packing List"
)
ppl1
.
start
()
ipl
.
start
()
ppl1
.
deliver
()
ipl
.
deliver
()
order
.
localBuild
()
order
.
localBuild
()
self
.
tic
()
self
.
tic
()
self
.
checkStock
(
resource
,
(
self
.
workshop
,
variation
,
10
))
self
.
checkStock
(
resource
,
(
self
.
workshop
,
variation
,
10
))
...
@@ -368,10 +375,10 @@ class TestMRPImplementation(TestMRPMixin):
...
@@ -368,10 +375,10 @@ class TestMRPImplementation(TestMRPMixin):
self
.
tic
()
self
.
tic
()
self
.
checkStock
(
resource
,
(
self
.
workshop
,
''
,
10
))
self
.
checkStock
(
resource
,
(
self
.
workshop
,
''
,
10
))
ppl
2
,
=
(
x
for
x
in
getRelatedDeliveryList
(
"Production Packing List"
)
ppl
,
=
(
x
for
x
in
getRelatedDeliveryList
(
"Production Packing List"
)
if
x
.
aq_base
is
not
ppl1
.
aq_base
)
if
x
.
aq_base
is
not
ipl
.
aq_base
)
ppl
2
.
start
()
ppl
.
start
()
ppl
2
.
deliver
()
ppl
.
deliver
()
self
.
tic
()
self
.
tic
()
self
.
checkStock
(
resource
,
(
self
.
destination
,
''
,
10
))
self
.
checkStock
(
resource
,
(
self
.
destination
,
''
,
10
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment