[FIX] stock_landed_cost: disable test with an invalid CoA
For now, these tests do not work with another CoA than the generic one. Depending on your testing infrastructure, they may or may not pass. We skip then invalid CoA's and plan to make them work in master.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
import unittest
|
||||
from odoo.addons.stock_landed_costs.tests.common import TestStockLandedCostsCommon
|
||||
|
||||
class TestLandedCosts(TestStockLandedCostsCommon):
|
||||
@@ -45,6 +45,10 @@ class TestLandedCosts(TestStockLandedCostsCommon):
|
||||
'location_dest_id': self.customer_location_id})
|
||||
|
||||
def test_00_landed_costs_on_incoming_shipment(self):
|
||||
chart_of_accounts = self.env.user.company_id.chart_template_id
|
||||
generic_coa = self.env.ref('l10n_generic_coa.configurable_chart_template')
|
||||
if chart_of_accounts != generic_coa:
|
||||
raise unittest.SkipTest('Skip this test as it works only with %s (%s loaded)' % (generic_coa.name, chart_of_accounts.name))
|
||||
""" Test landed cost on incoming shipment """
|
||||
#
|
||||
# (A) Purchase product
|
||||
@@ -94,6 +98,11 @@ class TestLandedCosts(TestStockLandedCostsCommon):
|
||||
self.assertEqual(account_entry['debit'], 430.0, 'Wrong Account Entry')
|
||||
|
||||
def test_01_negative_landed_costs_on_incoming_shipment(self):
|
||||
chart_of_accounts = self.env.user.company_id.chart_template_id
|
||||
generic_coa = self.env.ref('l10n_generic_coa.configurable_chart_template')
|
||||
if chart_of_accounts != generic_coa:
|
||||
raise unittest.SkipTest('Skip this test as it works only with %s (%s loaded)' % (generic_coa.name, chart_of_accounts.name))
|
||||
|
||||
""" Test negative landed cost on incoming shipment """
|
||||
#
|
||||
# (A) Purchase Product
|
||||
|
||||
Reference in New Issue
Block a user