[MERGE] forward port branch saas-11.2 up to e1a2b299b23

This commit is contained in:
Christophe Simonis
2018-03-23 16:21:58 +01:00
3 changed files with 26 additions and 13 deletions
+19 -9
View File
@@ -25,17 +25,34 @@ class TestSaleCouponCommon(common.TransactionCase):
self.uom_unit = self.env.ref('uom.product_uom_unit')
# Taxes
self.tax_15pc_excl = self.env['account.tax'].create({
'name': "Tax 15%",
'amount_type': 'percent',
'amount': 15,
'type_tax_use': 'sale',
})
self.tax_10pc_incl = self.env['account.tax'].create({
'name': "10% Tax incl",
'amount_type': 'percent',
'amount': 10,
'price_include': True,
})
#products
self.product_A = self.env['product.product'].create({
'name': 'Product A',
'list_price': 100,
'sale_ok': True
'sale_ok': True,
'taxes_id': [(6, 0, [self.tax_15pc_excl.id])],
})
self.product_B = self.env['product.product'].create({
'name': 'Product B',
'list_price': 5,
'sale_ok': True
'sale_ok': True,
'taxes_id': [(6, 0, [self.tax_15pc_excl.id])],
})
# Immediate Program By A + B: get B free
@@ -57,10 +74,3 @@ class TestSaleCouponCommon(common.TransactionCase):
'rule_products_domain': "[('id', 'in', [%s])]" % (self.product_A.id),
'active': True,
})
self.tax_10pc_incl = self.env['account.tax'].create({
'name': "10% Tax incl",
'amount_type': 'percent',
'amount': 10,
'price_include': True,
})