From 4fa3f961217b13a3550e620329cf0356e66bc374 Mon Sep 17 00:00:00 2001 From: ruthra kumar Date: Mon, 10 Jul 2023 15:25:11 +0530 Subject: [PATCH] chore: fix failing test case --- .../test_tax_withholding_category.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/erpnext/accounts/doctype/tax_withholding_category/test_tax_withholding_category.py b/erpnext/accounts/doctype/tax_withholding_category/test_tax_withholding_category.py index 4580b13613c..ac84217e6f9 100644 --- a/erpnext/accounts/doctype/tax_withholding_category/test_tax_withholding_category.py +++ b/erpnext/accounts/doctype/tax_withholding_category/test_tax_withholding_category.py @@ -4,6 +4,7 @@ import unittest import frappe +from frappe.tests.utils import change_settings from frappe.utils import today from erpnext.accounts.utils import get_fiscal_year @@ -152,6 +153,10 @@ class TestTaxWithholdingCategory(unittest.TestCase): for d in reversed(invoices): d.cancel() + @change_settings( + "Accounts Settings", + {"unlink_payment_on_cancellation_of_invoice": 1}, + ) def test_tcs_on_unallocated_advance_payments(self): frappe.db.set_value( "Customer", "Test TCS Customer", "tax_withholding_category", "Cumulative Threshold TCS"