fix: Uncommentt test

This commit is contained in:
Deepesh Garg 2021-05-21 11:15:18 +05:30
parent b07f7d1b70
commit 6f84cee6fe

View File

@ -991,30 +991,30 @@ class TestPurchaseInvoice(unittest.TestCase):
self.assertEqual(expected_gle[i][1], gle.debit) self.assertEqual(expected_gle[i][1], gle.debit)
self.assertEqual(expected_gle[i][2], gle.credit) self.assertEqual(expected_gle[i][2], gle.credit)
# Create Purchase Invoice against Purchase Order Create Purchase Invoice against Purchase Order
# purchase_invoice = get_mapped_purchase_invoice(po.name) purchase_invoice = get_mapped_purchase_invoice(po.name)
# purchase_invoice.allocate_advances_automatically = 1 purchase_invoice.allocate_advances_automatically = 1
# purchase_invoice.save() purchase_invoice.save()
# purchase_invoice.submit() purchase_invoice.submit()
# # Check GLE for Purchase Invoice # Check GLE for Purchase Invoice
# # Zero net effect on final TDS Payable on invoice # Zero net effect on final TDS Payable on invoice
# expected_gle = [ expected_gle = [
# ['_Test Account Excise Duty - _TC', 0, 6000], ['_Test Account Excise Duty - _TC', 0, 6000],
# ['Cost of Goods Sold - _TC', 30000, 0], ['Cost of Goods Sold - _TC', 30000, 0],
# ['Creditors - _TC', 0, 24000], ['Creditors - _TC', 0, 24000],
# ['TDS Payable - _TC', 6000, 6000], ['TDS Payable - _TC', 6000, 6000],
# ] ]
# gl_entries = frappe.db.sql("""select account, debit, credit gl_entries = frappe.db.sql("""select account, debit, credit
# from `tabGL Entry` from `tabGL Entry`
# where voucher_type='Purchase Invoice' and voucher_no=%s where voucher_type='Purchase Invoice' and voucher_no=%s
# order by account asc""", (purchase_invoice.name), as_dict=1) order by account asc""", (purchase_invoice.name), as_dict=1)
# for i, gle in enumerate(gl_entries): for i, gle in enumerate(gl_entries):
# self.assertEqual(expected_gle[i][0], gle.account) self.assertEqual(expected_gle[i][0], gle.account)
# self.assertEqual(expected_gle[i][1], gle.debit) self.assertEqual(expected_gle[i][1], gle.debit)
# self.assertEqual(expected_gle[i][2], gle.credit) self.assertEqual(expected_gle[i][2], gle.credit)
def update_tax_witholding_category(company, account, date): def update_tax_witholding_category(company, account, date):
from erpnext.accounts.utils import get_fiscal_year from erpnext.accounts.utils import get_fiscal_year