diff --git a/erpnext/hr/doctype/leave_application/test_leave_application.py b/erpnext/hr/doctype/leave_application/test_leave_application.py index 1532e8534b0..db46856fed5 100644 --- a/erpnext/hr/doctype/leave_application/test_leave_application.py +++ b/erpnext/hr/doctype/leave_application/test_leave_application.py @@ -369,7 +369,7 @@ class TestLeaveApplication(unittest.TestCase): employee = get_employee() leave_type = 'Test Earned Leave Type' if not frappe.db.exists('Leave Type', leave_type): - leave_type = frappe.get_doc(dict( + leave_type_doc = frappe.get_doc(dict( leave_type_name = leave_type, doctype = 'Leave Type', is_earned_leave = 1, @@ -448,4 +448,4 @@ def allocate_leaves(employee, leave_period, leave_type, new_leaves_allocated, el "docstatus": 1 }).insert() - allocate_leave.submit() \ No newline at end of file + allocate_leave.submit()