summaryrefslogtreecommitdiff
path: root/addons/mrp/tests/test_order.py
diff options
context:
space:
mode:
authorChristophe Simonis <chs@odoo.com>2019-04-04 11:20:03 +0200
committerChristophe Simonis <chs@odoo.com>2019-04-04 11:20:03 +0200
commitd32420397d6500f46d3defa2a840e4f580a13496 (patch)
tree4cdf23dbe8147fa8642f9f42e6778a7985eb7cae /addons/mrp/tests/test_order.py
parentc0cf4049b2a4a7c51169ea88569fd7f89e503a59 (diff)
parent251021796c25676f5c341e0a3fc3ba4c9feb85bb (diff)
[MERGE] forward port branch 12.0 up to 251021796c2
Diffstat (limited to 'addons/mrp/tests/test_order.py')
-rw-r--r--addons/mrp/tests/test_order.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/addons/mrp/tests/test_order.py b/addons/mrp/tests/test_order.py
index ac4ec19b748..ac21f1fddf1 100644
--- a/addons/mrp/tests/test_order.py
+++ b/addons/mrp/tests/test_order.py
@@ -561,6 +561,9 @@ class TestMrpOrder(TestMrpCommon):
'active_ids': [mo.id],
}))
produce_form.product_qty = 1.0
+ for i in range(len(produce_form.produce_line_ids)):
+ with produce_form.produce_line_ids.edit(i) as line:
+ line.qty_done += 1
product_produce = produce_form.save()
product_produce.lot_id = final_product_lot.id
# product 1 lot 1 shelf1
@@ -568,8 +571,6 @@ class TestMrpOrder(TestMrpCommon):
# product 1 lot 2
self.assertEqual(len(product_produce.produce_line_ids), 4, 'You should have 4 produce lines. lot 1 shelf_1, lot 1 shelf_2, lot2 and for product which have tracking None')
- for produce_line in product_produce.produce_line_ids:
- produce_line.qty_done = produce_line.qty_to_consume + 1
product_produce.do_produce()
move_1 = mo.move_raw_ids.filtered(lambda m: m.product_id == p1)