generated from coulomb/repo-seed
feat(tasks): adopt canonical task statuses
This commit is contained in:
@@ -35,7 +35,7 @@ async def _create_workstream(client, topic_id):
|
||||
return r.json()
|
||||
|
||||
|
||||
async def _create_task(client, workstream_id, title="Test task", status="blocked"):
|
||||
async def _create_task(client, workstream_id, title="Test task", status="wait"):
|
||||
r = await client.post("/tasks/", json={
|
||||
"workstream_id": workstream_id, "title": title,
|
||||
})
|
||||
@@ -43,7 +43,7 @@ async def _create_task(client, workstream_id, title="Test task", status="blocked
|
||||
task = r.json()
|
||||
if status != "todo":
|
||||
patch = {"status": status}
|
||||
if status == "blocked":
|
||||
if status == "wait":
|
||||
patch["blocking_reason"] = "Waiting for capability request"
|
||||
r2 = await client.patch(f"/tasks/{task['id']}", json=patch)
|
||||
assert r2.status_code == 200, r2.text
|
||||
@@ -229,7 +229,7 @@ class TestCapabilityRequestLifecycle:
|
||||
await _setup_two_domains(client)
|
||||
topic = await _create_topic(client, "custodian")
|
||||
ws = await _create_workstream(client, topic["id"])
|
||||
task = await _create_task(client, ws["id"], status="blocked")
|
||||
task = await _create_task(client, ws["id"], status="wait")
|
||||
|
||||
req = await _create_request(client, blocking_task_id=task["id"])
|
||||
|
||||
|
||||
Reference in New Issue
Block a user