mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-09 08:02:51 +00:00
test: fix shift type not found (#24929)
This commit is contained in:
@@ -7,6 +7,8 @@ import frappe
|
|||||||
import unittest
|
import unittest
|
||||||
from frappe.utils import nowdate, add_days
|
from frappe.utils import nowdate, add_days
|
||||||
|
|
||||||
|
test_dependencies = ["Shift Type"]
|
||||||
|
|
||||||
class TestShiftRequest(unittest.TestCase):
|
class TestShiftRequest(unittest.TestCase):
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
for doctype in ["Shift Request", "Shift Assignment"]:
|
for doctype in ["Shift Request", "Shift Assignment"]:
|
||||||
|
|||||||
8
erpnext/hr/doctype/shift_type/test_records.json
Normal file
8
erpnext/hr/doctype/shift_type/test_records.json
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
[
|
||||||
|
{
|
||||||
|
"doctype": "Shift Type",
|
||||||
|
"name": "Day Shift",
|
||||||
|
"start_time": "9:00:00",
|
||||||
|
"end_time": "18:00:00"
|
||||||
|
}
|
||||||
|
]
|
||||||
@@ -7,14 +7,4 @@ import frappe
|
|||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
class TestShiftType(unittest.TestCase):
|
class TestShiftType(unittest.TestCase):
|
||||||
def test_make_shift_type(self):
|
pass
|
||||||
if frappe.db.exists("Shift Type", "Day Shift"):
|
|
||||||
return
|
|
||||||
shift_type = frappe.get_doc({
|
|
||||||
"doctype": "Shift Type",
|
|
||||||
"name": "Day Shift",
|
|
||||||
"start_time": "9:00:00",
|
|
||||||
"end_time": "18:00:00"
|
|
||||||
})
|
|
||||||
shift_type.insert()
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user