Answer stability round 2: 0 🔴, 1 🟡 (0 misread); keep a Rust file whose modules cannot be told apart as Haiku left it where the planted file has no module
CI / tests (pull_request) Successful in 6m22s

This commit is contained in:
2026-11-26 02:03:10 +01:00
parent b0c5aa3390
commit 7c01eb1f8b
4 changed files with 19 additions and 6 deletions
+5
View File
@@ -143,6 +143,11 @@ class WithTestsOfTest(unittest.TestCase):
def test_takes_the_planted_file_where_the_fixed_modules_cannot_be_told_apart(self):
self.assertEqual(with_tests_of(LIB, "fn broken() {"), LIB)
def test_takes_the_file_as_fixed_where_planted_has_no_module_and_the_fixed_modules_cannot_be_told_apart(self):
for planted in ("", "fn a() {}\n"):
with self.subTest(planted=planted):
self.assertEqual(with_tests_of(planted, "fn broken() {"), "fn broken() {")
if __name__ == "__main__":
unittest.main()