diff options
Diffstat (limited to 'addons/mrp/tests/common.py')
| -rw-r--r-- | addons/mrp/tests/common.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/addons/mrp/tests/common.py b/addons/mrp/tests/common.py index 6e70957237d..832a7f2e442 100644 --- a/addons/mrp/tests/common.py +++ b/addons/mrp/tests/common.py @@ -7,7 +7,7 @@ from odoo.addons.stock.tests import common2 class TestMrpCommon(common2.TestStockCommon): @classmethod - def generate_mo(self, tracking_final='none', tracking_base_1='none', tracking_base_2='none', qty_final=5, qty_base_1=4, qty_base_2=1, picking_type_id=False): + def generate_mo(self, tracking_final='none', tracking_base_1='none', tracking_base_2='none', qty_final=5, qty_base_1=4, qty_base_2=1, picking_type_id=False, consumption=False): """ This function generate a manufacturing order with one final product and two consumed product. Arguments allows to choose the tracking/qty for each different products. It returns the @@ -34,6 +34,7 @@ class TestMrpCommon(common2.TestStockCommon): 'product_uom_id': self.uom_unit.id, 'product_qty': 1.0, 'type': 'normal', + 'consumption': consumption if consumption else 'flexible', 'bom_line_ids': [ (0, 0, {'product_id': product_to_use_2.id, 'product_qty': qty_base_2}), (0, 0, {'product_id': product_to_use_1.id, 'product_qty': qty_base_1}) |
