Exemplo n.º 1
0
 def test_clean_cron_string_invalid(self):
     job = self.JobClass()
     job.cron_string = 'not-a-cron-string'
     job.queue = list(settings.RQ_QUEUES)[0]
     job.callable = 'scheduler.tests.test_job'
     with self.assertRaises(ValidationError):
         job.clean_cron_string()
Exemplo n.º 2
0
 def test_clean_cron_string_invalid(self):
     job = self.JobClass()
     job.cron_string = 'not-a-cron-string'
     job.queue = list(settings.RQ_QUEUES)[0]
     job.callable = 'scheduler.tests.test_job'
     with self.assertRaises(ValidationError):
         job.clean_cron_string()