diff options
| author | Arnold Moyaux <arm@odoo.com> | 2019-07-31 13:48:26 +0000 |
|---|---|---|
| committer | Arnold Moyaux <arm@odoo.com> | 2019-08-19 15:03:59 +0000 |
| commit | 875d99812f8799ae21c850e06c2f35b200eaed75 (patch) | |
| tree | e00237cd225d4f0384752078108384c9ef058a1c /addons/mrp_subcontracting/tests | |
| parent | 33cf89a6c675744338654ebf66e3c75f77bb341c (diff) | |
[FIX] mrp_subcontracting: allow to create lot.
due to commit 108ee65af2a88d61526dc047043138bddc3f9b63#diff-99ad190cf09687f6efdebc1f7636062c
picking type for subcontracting order use field use_create_components_lots
instead of classic picking type.
Diffstat (limited to 'addons/mrp_subcontracting/tests')
| -rw-r--r-- | addons/mrp_subcontracting/tests/test_subcontracting.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/addons/mrp_subcontracting/tests/test_subcontracting.py b/addons/mrp_subcontracting/tests/test_subcontracting.py index 30b9e835d72..34c98d5264c 100644 --- a/addons/mrp_subcontracting/tests/test_subcontracting.py +++ b/addons/mrp_subcontracting/tests/test_subcontracting.py @@ -68,12 +68,16 @@ class TestSubcontractingFlows(SavepointCase): bom_line.product_qty = 1 cls.comp2_bom = bom_form.save() + cls.warehouse = cls.env['stock.warehouse'].search([], limit=1) + def test_flow_1(self): """ Don't tick any route on the components and trigger the creation of the subcontracting manufacturing order through a receipt picking. Create a reordering rule in the subcontracting locations for a component and run the scheduler to resupply. Checks if the resupplying actually works """ + # Check subcontracting picking Type + self.assertTrue(all(self.env['stock.warehouse'].search([]).with_context(active_test=False).mapped('subcontracting_type_id.use_create_components_lots'))) # Create a receipt picking from the subcontractor picking_form = Form(self.env['stock.picking']) picking_form.picking_type_id = self.env.ref('stock.picking_type_in') |
