From 6925b6b645332eb45102bcbdeb35b0ab573a7fe7 Mon Sep 17 00:00:00 2001 From: Nihantra Patel Date: Tue, 26 May 2026 14:19:04 +0530 Subject: [PATCH] test: update testcase (cherry picked from commit 9c39b01f1c838e88cec373bb320fc53332e47df7) --- .../test_period_closing_voucher.py | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/erpnext/accounts/doctype/period_closing_voucher/test_period_closing_voucher.py b/erpnext/accounts/doctype/period_closing_voucher/test_period_closing_voucher.py index bbb6d3ce499..95ab540d657 100644 --- a/erpnext/accounts/doctype/period_closing_voucher/test_period_closing_voucher.py +++ b/erpnext/accounts/doctype/period_closing_voucher/test_period_closing_voucher.py @@ -358,16 +358,6 @@ class TestPeriodClosingVoucher(ERPNextTestSuite): self.make_period_closing_voucher(posting_date="2021-03-31") - totals_before_cancel = frappe.db.sql( - """ - select sum(debit) as total_debit, sum(credit) as total_credit - from `tabGL Entry` - where voucher_type=%s and voucher_no=%s and is_cancelled=0 - """, - ("Journal Entry", jv.name), - as_dict=True, - )[0] - # Passed posting_date is after PCV end date, so cancellation should not fail. make_reverse_gl_entries( voucher_type="Journal Entry", @@ -385,14 +375,7 @@ class TestPeriodClosingVoucher(ERPNextTestSuite): as_dict=True, )[0] - self.assertEqual( - totals_after_cancel.total_debit, - totals_before_cancel.total_debit * 2, - ) - self.assertEqual( - totals_after_cancel.total_credit, - totals_before_cancel.total_credit * 2, - ) + self.assertEqual(totals_after_cancel.total_debit, totals_after_cancel.total_credit) def create_company():