fix(test): the test event has hanged frequency

This commit is contained in:
Rushabh Mehta 2019-11-07 12:34:38 +05:30
parent 8d4610504a
commit d1e4616231

View file

@ -40,7 +40,7 @@ class TestScheduledJobType(unittest.TestCase):
self.assertFalse(job.is_event_due(get_datetime('2019-01-01 23:59:59')))
def test_weekly_job(self):
job = frappe.get_doc('Scheduled Job Type', dict(method = 'frappe.utils.change_log.check_for_update'))
job = frappe.get_doc('Scheduled Job Type', dict(method = 'frappe.social.doctype.energy_point_log.energy_point_log.send_weekly_summary'))
job.db_set('last_execution', '2019-01-01 00:00:00')
self.assertTrue(job.is_event_due(get_datetime('2019-01-06 00:00:01')))
self.assertFalse(job.is_event_due(get_datetime('2019-01-02 00:00:06')))