[IMP] account_payment_sale: Improve tests to prevent error with pricelist_id field

Remove the pricelist_id assignment (leave the default one) because it may fail
if the user does not have the product.group_product_product_pricelist group
This commit is contained in:
Víctor Martínez
2024-05-17 08:51:30 +02:00
parent 329022f464
commit fc15c97550

View File

@@ -10,7 +10,6 @@ class TestSaleOrder(CommonTestCase):
def create_sale_order(self, payment_mode=None):
with Form(self.env["sale.order"]) as sale_form:
sale_form.partner_id = self.base_partner
sale_form.pricelist_id = self.env.ref("product.list0")
for (_, p) in self.products.items():
with sale_form.order_line.new() as order_line:
order_line.product_id = p