chore: Remove domains from Setup

This commit is contained in:
Deepesh Garg
2022-04-27 13:32:51 +05:30
parent deed9702cf
commit 429361ce87
19 changed files with 3 additions and 843 deletions

View File

@@ -33,10 +33,8 @@ def before_tests():
"email": "test@erpnext.com",
"password": "test",
"chart_of_accounts": "Standard",
"domains": ["Manufacturing"],
}
)
_enable_all_domains()
frappe.db.sql("delete from `tabLeave Allocation`")
frappe.db.sql("delete from `tabLeave Application`")
@@ -131,17 +129,9 @@ def format_ces_api(data, param):
def enable_all_roles_and_domains():
"""enable all roles and domain for testing"""
_enable_all_domains()
_enable_all_roles_for_admin()
def _enable_all_domains():
domains = frappe.get_all("Domain", pluck="name")
if not domains:
return
frappe.get_single("Domain Settings").set_active_domains(domains)
def _enable_all_roles_for_admin():
from frappe.desk.page.setup_wizard.setup_wizard import add_all_roles_to