Answer stability round 1: 0 🔴, 2 🟡 (0 misread); show reuses item_details and reads todo.md alone, and the --calls file is owner-only

This commit is contained in:
2026-11-12 08:23:35 +01:00
parent 0ca23f5612
commit 9439d7ec5c
5 changed files with 80 additions and 38 deletions
@@ -129,6 +129,14 @@ class Main(unittest.TestCase):
self.assertIn("| tea pr create | 1 | 1 |", ran.stdout)
self.assertEqual([json.loads(line) for line in saved.read_text().splitlines()], [{"chunk": 1, "pattern": "tea pr create", "seconds": 0.0, "command_characters": 13, "result_characters": 2, "command": "tea pr create"}])
def test_makes_the_calls_file_readable_by_its_owner_alone_even_where_it_existed(self):
saved = self.home / "calls.jsonl"
saved.write_text("old")
saved.chmod(0o644)
self.assertEqual(self.run_tool("0.2.0", "--calls", str(saved)).returncode, 0)
self.assertEqual(saved.stat().st_mode & 0o777, 0o600)
self.assertNotIn("old", saved.read_text())
def test_takes_the_calls_flag_before_the_version_too(self):
saved = self.home / "calls.jsonl"
self.assertEqual(self.run_tool("--calls", str(saved), "0.2.0").returncode, 0)