Answer product-owner round 1: 0 🔴, 1 🟡 (0 misread); a kept run's header records claude's exit code and stderr
This commit is contained in:
@@ -111,7 +111,7 @@ class ArchivedRuns(unittest.TestCase):
|
||||
first, second = (path.read_text(encoding="utf-8").splitlines() for path in self.kept())
|
||||
prompts = sorted((json.loads(lines[0]) for lines in (first, second)), key=lambda header: header["prompt"])
|
||||
self.assertEqual(prompts, [
|
||||
{"type": "replay_run", "args": ["-p", "--agent", "prose-reviewer"], "cwd": "/clone", "prompt": prompt} for prompt in ("Review it.", "Review that.")
|
||||
{"type": "replay_run", "args": ["-p", "--agent", "prose-reviewer"], "cwd": "/clone", "prompt": prompt, "returncode": 0, "stderr": ""} for prompt in ("Review it.", "Review that.")
|
||||
])
|
||||
self.assertEqual(first[1:], stream.splitlines())
|
||||
|
||||
@@ -126,7 +126,8 @@ class ArchivedRuns(unittest.TestCase):
|
||||
run([], "/r", "p")
|
||||
run([], "/r", "p")
|
||||
self.assertEqual(len(self.kept()), 1)
|
||||
self.assertIn("half a stream", self.kept()[0].read_text(encoding="utf-8"))
|
||||
kept = self.kept()[0].read_text(encoding="utf-8").splitlines()
|
||||
self.assertEqual((json.loads(kept[0])["returncode"], json.loads(kept[0])["stderr"], kept[1]), (1, "boom", "half a stream"))
|
||||
|
||||
def test_keeps_nothing_where_claude_did_not_start_and_says_where_it_could_not_keep_a_run(self):
|
||||
def missing(args, cwd, prompt):
|
||||
|
||||
Reference in New Issue
Block a user