Skip to content

Commit 955c954

Browse files
committed
Fix maxconcurrency test
1 parent 255aa0c commit 955c954

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

tests/test_interrupts.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -333,11 +333,12 @@ def test_interrupt_maxconcurrency(worker):
333333

334334
worker.wait_for_tasks_results(job_ids, accept_statuses=["success", "failed", "maxconcurrency"])
335335
job_statuses = [Job(job_id).fetch().data["status"] for job_id in job_ids]
336-
assert job_statuses == ["success", "maxconcurrency"]
336+
assert set(job_statuses) == set(["success", "maxconcurrency"])
337337

338338
# the job concurrency key must be equal to 0
339339
last_job_id = worker.send_task("tests.tasks.concurrency.LockedAdd",
340340
{"a": 1, "b": 1, "sleep": 2}, block=False
341341
)
342+
342343
last_job = Job(last_job_id).wait(poll_interval=0.01)
343344
assert last_job.get("status") == "success"

0 commit comments

Comments
 (0)