mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-29 18:04:46 +00:00
fix: test case
This commit is contained in:
@@ -18,6 +18,7 @@ class TestAccountingDimensionFilter(unittest.TestCase):
|
|||||||
si = create_sales_invoice(do_not_save=1)
|
si = create_sales_invoice(do_not_save=1)
|
||||||
si.items[0].cost_center = 'Main - _TC'
|
si.items[0].cost_center = 'Main - _TC'
|
||||||
si.department = 'Accounts - _TC'
|
si.department = 'Accounts - _TC'
|
||||||
|
si.location = 'Block 1'
|
||||||
si.save()
|
si.save()
|
||||||
|
|
||||||
self.assertRaises(InvalidAccountDimensionError, si.submit)
|
self.assertRaises(InvalidAccountDimensionError, si.submit)
|
||||||
@@ -25,6 +26,7 @@ class TestAccountingDimensionFilter(unittest.TestCase):
|
|||||||
def test_mandatory_dimension_validation(self):
|
def test_mandatory_dimension_validation(self):
|
||||||
si = create_sales_invoice(do_not_save=1)
|
si = create_sales_invoice(do_not_save=1)
|
||||||
si.department = ''
|
si.department = ''
|
||||||
|
si.location = 'Block 1'
|
||||||
|
|
||||||
# Test with no department for Sales Account
|
# Test with no department for Sales Account
|
||||||
si.items[0].department = ''
|
si.items[0].department = ''
|
||||||
|
|||||||
Reference in New Issue
Block a user