fix: couple of travis fixes (#24554)
Co-authored-by: Suraj Shetty <13928957+surajshetty3416@users.noreply.github.com>
This commit is contained in:
parent
4742a25942
commit
c4a1bb0e1c
@ -139,6 +139,7 @@ def create_inpatient(patient):
|
|||||||
inpatient_record.phone = patient_obj.phone
|
inpatient_record.phone = patient_obj.phone
|
||||||
inpatient_record.inpatient = "Scheduled"
|
inpatient_record.inpatient = "Scheduled"
|
||||||
inpatient_record.scheduled_date = today()
|
inpatient_record.scheduled_date = today()
|
||||||
|
inpatient_record.company = "_Test Company"
|
||||||
return inpatient_record
|
return inpatient_record
|
||||||
|
|
||||||
|
|
||||||
|
@ -16,11 +16,13 @@ class TestEmployee(unittest.TestCase):
|
|||||||
employee = frappe.get_doc("Employee", frappe.db.sql_list("select name from tabEmployee limit 1")[0])
|
employee = frappe.get_doc("Employee", frappe.db.sql_list("select name from tabEmployee limit 1")[0])
|
||||||
employee.date_of_birth = "1992" + frappe.utils.nowdate()[4:]
|
employee.date_of_birth = "1992" + frappe.utils.nowdate()[4:]
|
||||||
employee.company_email = "test@example.com"
|
employee.company_email = "test@example.com"
|
||||||
|
employee.company = "_Test Company"
|
||||||
employee.save()
|
employee.save()
|
||||||
|
|
||||||
from erpnext.hr.doctype.employee.employee import get_employees_who_are_born_today, send_birthday_reminders
|
from erpnext.hr.doctype.employee.employee import get_employees_who_are_born_today, send_birthday_reminders
|
||||||
|
|
||||||
self.assertTrue(employee.name in [e.name for e in get_employees_who_are_born_today()])
|
employees_born_today = get_employees_who_are_born_today()
|
||||||
|
self.assertTrue(employees_born_today.get("_Test Company"))
|
||||||
|
|
||||||
frappe.db.sql("delete from `tabEmail Queue`")
|
frappe.db.sql("delete from `tabEmail Queue`")
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user