mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-23 15:09:20 +00:00
Cleanup journal entries
This commit is contained in:
@@ -15,8 +15,11 @@ class TestSalesPaymentSummary(unittest.TestCase):
|
|||||||
def setUpClass(self):
|
def setUpClass(self):
|
||||||
create_records()
|
create_records()
|
||||||
pes = frappe.get_all("Payment Entry")
|
pes = frappe.get_all("Payment Entry")
|
||||||
|
jes = frappe.get_all("Journal Entry")
|
||||||
for pe in pes:
|
for pe in pes:
|
||||||
frappe.db.set_value("Payment Entry", pe.name, "docstatus", 2)
|
frappe.db.set_value("Payment Entry", pe.name, "docstatus", 2)
|
||||||
|
for je in jes:
|
||||||
|
frappe.db.set_value("Journal Entry", je.name, "docstatus", 2)
|
||||||
|
|
||||||
def test_get_mode_of_payments(self):
|
def test_get_mode_of_payments(self):
|
||||||
filters = get_filters()
|
filters = get_filters()
|
||||||
@@ -51,8 +54,6 @@ class TestSalesPaymentSummary(unittest.TestCase):
|
|||||||
pe.cancel()
|
pe.cancel()
|
||||||
|
|
||||||
mop = get_mode_of_payments(filters)
|
mop = get_mode_of_payments(filters)
|
||||||
print(frappe.get_all("Payment Entry", filters={"docstatus": 1}))
|
|
||||||
print(mop)
|
|
||||||
self.assertTrue('Credit Card' in mop.values()[0])
|
self.assertTrue('Credit Card' in mop.values()[0])
|
||||||
self.assertTrue('Cash' not in mop.values()[0])
|
self.assertTrue('Cash' not in mop.values()[0])
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user