From ec8352b09409a27dd88113f9d3fd59bd0f211dab Mon Sep 17 00:00:00 2001 From: Abdellatif Benzbiria Date: Fri, 1 Nov 2024 04:23:50 +0100 Subject: [PATCH] TA#70584 [14.0][DEL] stock_location_production --- project_material/tests/test_consumption_route.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/project_material/tests/test_consumption_route.py b/project_material/tests/test_consumption_route.py index db995743..1660bcac 100644 --- a/project_material/tests/test_consumption_route.py +++ b/project_material/tests/test_consumption_route.py @@ -17,10 +17,10 @@ def setUpClass(cls): cls.new_warehouse = cls.env["stock.warehouse"].search( [("company_id", "=", cls.new_company.id)], limit=1 ) - property_stock_production = cls.env['ir.property'].sudo().search( - [('name', '=', 'property_stock_production'), - ('company_id', '=', cls.env.user.company_id.id)]) - cls.location_id = property_stock_production.value_reference.split(',')[-1] + cls.location_id = cls.env["ir.property"].with_company( + cls.new_warehouse.company_id.id)._get( + "property_stock_production", "product.template") + class TestConsumptionStep(ConsumptionRouteCase):