예제 #1
0
파일: test_unit_1.py 프로젝트: ocoffey/TA
 def test_eval_go_prev(self):
     llgp = CDLL()
     for i in range(5):
         self.insert(llgp, "00:00:0" + str(i))
     llgp.current = llgp.head
     try:
         self.assertEqual(llgp.current.time, "00:00:00")
     except AssertionError:
         assert False, "Head Not Equal"
     llgp.go_prev()
     try:
         self.assertEqual(llgp.current.time, "00:00:04")
     except AssertionError:
         assert False, "Previous Element Not Equal"
예제 #2
0
파일: test_unit_1.py 프로젝트: ocoffey/TA
 def test_eval_go_next(self):
     llgn = CDLL()
     for i in range(2):
         self.insert(llgn, "00:00:0" + str(i))
     llgn.current = llgn.head
     try:
         self.assertEqual(llgn.current.time, "00:00:00")
     except AssertionError:
         assert False, "Head Not Equal"
     llgn.go_next()
     try:
         self.assertEqual(llgn.current.time, "00:00:01")
     except AssertionError:
         assert False, "Next Element Not Equal"