This commit is contained in:
Rushabh Mehta 2013-02-06 08:49:59 +05:30
parent c2563effbf
commit 509f17c3a4

View File

@ -1,9 +1,9 @@
import sys import sys
import unittest import unittest
from hr.doctype.leave_application.leave_application import test_records, LeaveDayBlockedError from hr.doctype.leave_application.leave_application import test_records, LeaveDayBlockedError
class TestLeaveApplication(unittest.TestCase): class TestLeaveApplication(unittest.TestCase):
def setUp(self): def setUp(self):
from webnotes.test_runner import make_test_records from webnotes.test_runner import make_test_records
make_test_records("Leave Application") make_test_records("Leave Application")
@ -18,7 +18,7 @@ class TestLeaveApplication(unittest.TestCase):
application.doc.to_date = "2013-01-05" application.doc.to_date = "2013-01-05"
self.assertRaises(LeaveDayBlockedError, application.insert) self.assertRaises(LeaveDayBlockedError, application.insert)
if __name__=="__main__": if __name__=="__main__":
sys.path.extend(["app", "lib"]) sys.path.extend(["app", "lib"])
import webnotes import webnotes
webnotes.connect() webnotes.connect()