mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-28 01:14:46 +00:00
chore: use frappe.in_test
This commit is contained in:
@@ -49,7 +49,7 @@ class VATAuditReport:
|
||||
self.sa_vat_accounts = frappe.get_all(
|
||||
"South Africa VAT Account", filters={"parent": self.filters.company}, pluck="account"
|
||||
)
|
||||
if not self.sa_vat_accounts and not frappe.flags.in_test and not frappe.flags.in_migrate:
|
||||
if not self.sa_vat_accounts and not frappe.in_test and not frappe.flags.in_migrate:
|
||||
link_to_settings = get_link_to_form(
|
||||
"South Africa VAT Settings", "", label="South Africa VAT Settings"
|
||||
)
|
||||
|
||||
@@ -57,7 +57,7 @@ def get_tax_accounts(company):
|
||||
tax_accounts_dict = frappe._dict()
|
||||
tax_accounts_list = frappe.get_all("UAE VAT Account", filters={"parent": company}, fields=["Account"])
|
||||
|
||||
if not tax_accounts_list and not frappe.flags.in_test:
|
||||
if not tax_accounts_list and not frappe.in_test:
|
||||
frappe.throw(_('Please set Vat Accounts for Company: "{0}" in UAE VAT Settings').format(company))
|
||||
for tax_account in tax_accounts_list:
|
||||
for _account, name in tax_account.items():
|
||||
|
||||
Reference in New Issue
Block a user