def enqueue_next(self, job):
        if not job.repeat:
            return

        if isinstance(job.repeat, datetime):
            if job.repeat <= now():
                return
            else:
                repeat = job.repeat
        else:
            repeat = job.repeat - 1 if job.repeat > 0 else -1
        timeout = job.timeout
        scheduled_for = job.scheduled_for + job.interval
        scheduled_for = get_restricted_datetime(scheduled_for, job.between, job.weekdays)
        status = Job.SCHEDULED if scheduled_for > job.scheduled_for else Job.QUEUED
        self.save_queue()
        job = Job.create(job.func, job.args, job.kwargs, connection=job.connection,
                         result_ttl=job.result_ttl,
                         scheduled_for=scheduled_for,
                         repeat=repeat,
                         interval=job.interval,
                         between=job.between,
                         weekdays=job.weekdays,
                         status=status)
        return self.enqueue_job(job, timeout=timeout)
Unittest runner
dataset/ETHPy150Open bretth/django-pq/pq/queue.py/Queue.enqueue_next--crossover with--dataset/ETHPy150Open ioflo/ioflo/ioflo/test/testTemplate.py/runSome