コード例 #1
0
 def test_date_is_gt_5(self):
     """date_is_gt: test de comparacion incorrecta por formato"""
     d1 = '2017-01-01 00:00:00'
     d2 = '2017-01-01 00:00:00'
     formatter = '%d/%m/%Y %H:%M:%S'
     test_list = list()
     test_list.append(d1)
     test_list.append(d2)
     test_list.append(formatter)
     op.date_is_gt(test_list)
コード例 #2
0
 def test_date_is_gt_7(self):
     """date_is_gt: test de comparacion correcta con fechas inversas"""
     d1 = '2017-01-01 00:00:00'
     d2 = '2017-01-31 00:00:00'
     test_list = list()
     test_list.append(d1)
     test_list.append(d2)
     res = op.date_is_gt(test_list)
     assert_false(res)
コード例 #3
0
 def test_date_is_gt_3(self):
     """date_is_gt: test de comparacion incorrecta por time"""
     d1 = '2017-01-01 00:00:00'
     d2 = '2017-01-01 11:00:00'
     test_list = list()
     test_list.append(d1)
     test_list.append(d2)
     res = op.date_is_gt(test_list)
     assert_false(res)
コード例 #4
0
 def test_date_is_gt_1(self):
     """date_is_gt: test de comparacion correcta"""
     d1 = '2017-01-31 00:00:00'
     d2 = '2017-01-01 00:00:00'
     test_list = list()
     test_list.append(d1)
     test_list.append(d2)
     res = op.date_is_gt(test_list)
     assert_true(res)
コード例 #5
0
 def test_date_is_gt_4(self):
     """date_is_gt: test de comparacion correcta con otro formato"""
     d1 = '01/01/2017 20:00:00'
     d2 = '01/01/2017 00:00:00'
     formatter = '%d/%m/%Y %H:%M:%S'
     test_list = list()
     test_list.append(d1)
     test_list.append(d2)
     test_list.append(formatter)
     res = op.date_is_gt(test_list)
     assert_true(res)