Answer stability round 1: 0 🔴, 1 🟡 (1 misread); leave a human's task unmoved and unawaited where the team's automation moves issues

This commit is contained in:
Lilleman
2026-11-19 23:54:55 +01:00
parent daee3c671f
commit 535ad7fd6a
2 changed files with 14 additions and 10 deletions
+7 -4
View File
@@ -50,8 +50,8 @@ class AHumanTaskThatBlocksAnIssue(DoEpicTest):
self.slept = slept
return self.run_main(["--chunk", "ABC-19", "ABC-12"], fake, MODELS)
def moved_to_an_unblocking_status(self, switch: str) -> bool:
"""Whether Jira counts the task done after its window's run, where the human moved it to an unblocking status and the config ends with switch."""
def moved_to_an_unblocking_status(self, switch: str, frees: tuple[str, dict[str, object]] = ("ABC-19", {"status": "Release Ready"}), starts: str = "ABC-21") -> bool:
"""Whether Jira counts the task done after its window's run, where the config ends with switch. frees is the change in Jira that ends the wait: by default the human moves the task to an unblocking status. starts is what the window then starts."""
with (self.home / ".claude-projects" / "do-epic" / "config.toml").open("a") as config:
config.write('jira-unblocking-statuses = ["Release Ready"]\n' + switch)
fake = FakeEffects(git=UNREAD, windows=WINDOW)
@@ -61,11 +61,11 @@ class AHumanTaskThatBlocksAnIssue(DoEpicTest):
slept.append(seconds)
self.assertLess(len(slept), 5, "the window still waits")
if len(slept) == 2:
self.epic.change("ABC-19", status="Release Ready")
self.epic.change(frees[0], **frees[1])
fake.effects = lambda made=fake.effects(): dataclasses.replace(made, sleep=sleep) # type: ignore[method-assign]
code, out, err = self.run_main(["--chunk", "ABC-19", "ABC-12"], fake, MODELS)
self.assertEqual((code, err, slept), (0, "", [60, 60]))
self.assertIn("the chunk finished; started ABC-21\n", out)
self.assertIn(f"the chunk finished; started {starts}\n", out)
return next(each.done for each in self.epic.issues if each.key == "ABC-19")
def test_a_task_the_human_moves_to_an_unblocking_status_no_longer_holds_up_an_issue_and_moves_to_done(self) -> None:
@@ -74,6 +74,9 @@ class AHumanTaskThatBlocksAnIssue(DoEpicTest):
def test_where_the_teams_automation_moves_issues_the_humans_task_stays_where_the_human_moved_it(self) -> None:
self.assertFalse(self.moved_to_an_unblocking_status("jira-automation-moves-issues = true\n"))
def test_where_the_teams_automation_moves_issues_a_task_that_blocks_no_open_issue_any_more_ends_its_window_unmoved(self) -> None:
self.assertFalse(self.moved_to_an_unblocking_status("jira-automation-moves-issues = true\n", ("ABC-21", {"done": True}), starts="no other"))
def test_a_task_holds_up_only_the_issues_no_unblocking_status_settles(self) -> None:
issues = [issue("ABC-19", "do-epic-human"), issue("ABC-20", "do-epic-claude", blockers=("ABC-19",), status="Release Ready"), issue("ABC-21", "do-epic-claude", blockers=("ABC-19",))]
self.assertEqual(holds_up("ABC-19", issues, {}, ("Release Ready",)), ["ABC-21"])