Files
odoo_source/addons/event_booth_sale/tests/common.py
T
Thibault Delavallée dd1a842c32 [IMP] event_booth(_sale): improve tests execution
Notably using post-install allows to run event_booth tests even when sale
dependencies are installed. Otherwise they cannot run at install due to
required column not being filled in DB.

X-original-commit: aa769df87c0ef0e7ac6924c3e8f5595e8c82eba7
Part-of: odoo/odoo#94475
2022-06-24 10:29:50 +02:00

32 lines
1012 B
Python

# -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from odoo.addons.event_booth.tests.common import TestEventBoothCommon
class TestEventBoothSaleCommon(TestEventBoothCommon):
@classmethod
def setUpClass(cls):
super(TestEventBoothSaleCommon, cls).setUpClass()
cls.event_booth_product = cls.env['product.product'].create({
'name': 'Test Booth Product',
'description_sale': 'Mighty Booth Description',
'list_price': 20,
'standard_price': 60.0,
'detailed_type': 'event_booth',
})
(cls.event_booth_category_1 + cls.event_booth_category_2).write({
'product_id': cls.event_booth_product.id,
})
cls.tax_10 = cls.env['account.tax'].sudo().create({
'name': 'Tax 10',
'amount': 10,
})
cls.test_pricelist = cls.env['product.pricelist'].sudo().create({
'name': 'Test Pricelist',
})