summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristophe Simonis <chs@odoo.com>2019-05-31 16:31:44 +0200
committerChristophe Simonis <chs@odoo.com>2019-05-31 16:31:44 +0200
commit995aa1685eece9ff1070a637d19d511fb1f80260 (patch)
treef8a012f12a4ada73c46a3117251abfda712bf24a
parentb1970c6f08d66cf5ae1ef2471d48d7f219bcd2fb (diff)
[FIX] purchase_stock: correctly set `cost_method` and `valuation` in tests
Oversight of previous forward-port.
-rw-r--r--addons/purchase_stock/tests/test_stockvaluation.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/addons/purchase_stock/tests/test_stockvaluation.py b/addons/purchase_stock/tests/test_stockvaluation.py
index ef9f4b66f5f..48bebcb747d 100644
--- a/addons/purchase_stock/tests/test_stockvaluation.py
+++ b/addons/purchase_stock/tests/test_stockvaluation.py
@@ -1172,8 +1172,8 @@ class TestStockValuationWithCOA(AccountingTestCase):
discount: 10
"""
self.env.user.company_id.anglo_saxon_accounting = True
- self.product1.product_tmpl_id.cost_method = 'fifo'
- self.product1.product_tmpl_id.valuation = 'real_time'
+ self.product1.categ_id.property_cost_method = 'fifo'
+ self.product1.categ_id.property_valuation = 'real_time'
self.product1.product_tmpl_id.invoice_policy = 'delivery'
self.product1.property_account_creditor_price_difference = self.price_diff_account
@@ -1222,8 +1222,8 @@ class TestStockValuationWithCOA(AccountingTestCase):
discount: 10
"""
self.env.user.company_id.anglo_saxon_accounting = True
- self.product1.product_tmpl_id.cost_method = 'fifo'
- self.product1.product_tmpl_id.valuation = 'real_time'
+ self.product1.categ_id.property_cost_method = 'fifo'
+ self.product1.categ_id.property_valuation = 'real_time'
self.product1.product_tmpl_id.invoice_policy = 'delivery'
self.product1.property_account_creditor_price_difference = self.price_diff_account
@@ -1271,8 +1271,8 @@ class TestStockValuationWithCOA(AccountingTestCase):
discount: 10
"""
self.env.user.company_id.anglo_saxon_accounting = True
- self.product1.product_tmpl_id.cost_method = 'fifo'
- self.product1.product_tmpl_id.valuation = 'real_time'
+ self.product1.categ_id.property_cost_method = 'fifo'
+ self.product1.categ_id.property_valuation = 'real_time'
self.product1.product_tmpl_id.invoice_policy = 'delivery'
self.product1.property_account_creditor_price_difference = self.price_diff_account