(arq_redis: ArqRedis, worker)
| 205 | |
| 206 | |
| 207 | async def test_custom_try2(arq_redis: ArqRedis, worker): |
| 208 | async def foobar(ctx): |
| 209 | if ctx['job_try'] == 3: |
| 210 | raise Retry() |
| 211 | return ctx['job_try'] |
| 212 | |
| 213 | j1 = await arq_redis.enqueue_job('foobar', _job_try=3) |
| 214 | w: Worker = worker(functions=[func(foobar, name='foobar')]) |
| 215 | await w.main() |
| 216 | r = await j1.result(poll_delay=0) |
| 217 | assert r == 4 |
| 218 | |
| 219 | |
| 220 | async def test_cant_pickle_arg(arq_redis: ArqRedis): |
nothing calls this directly
no test coverage detected
searching dependent graphs…