Skip to content

Commit

Permalink
Merge PR OCA#322 into 16.0
Browse files Browse the repository at this point in the history
Signed-off-by pedrobaeza
  • Loading branch information
OCA-git-bot committed Mar 4, 2025
2 parents 32ec24b + 66adfae commit 7539d67
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,15 @@ class TestSaleLayoutCategoryHideDetail(SaleCommon):
@classmethod
def setUpClass(cls):
super(TestSaleLayoutCategoryHideDetail, cls).setUpClass()
if not cls.env.company.chart_template_id:
# Load a CoA if there's none in current company
coa = cls.env.ref("l10n_generic_coa.configurable_chart_template", False)
if not coa:
# Load the first available CoA
coa = cls.env["account.chart.template"].search(
[("visible", "=", True)], limit=1
)
coa.try_loading(company=cls.env.company, install_demo=False)
cls.product = cls.env["product.product"].create(
{"name": "Producto test", "type": "consu", "invoice_policy": "order"}
)
Expand Down

0 comments on commit 7539d67

Please sign in to comment.