The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
test(e2e): hostile commit cells for fork sync, leftover ZIP backup, guessed checkout, killed rollback
Teknium86e2df1bcb0b
diff --git a/tests/hermes_cli/test_update_zip_completion.py b/tests/hermes_cli/test_update_zip_completion.pyindex f9ecb7d98e3..69a7bdd9b7b 100644--- a/tests/hermes_cli/test_update_zip_completion.py+++ b/tests/hermes_cli/test_update_zip_completion.py@@ -202,15 +202,16 @@ def test_zip_failure_recovers_pause_without_completion_mutations(zip_update, monmonkeypatch.setattr(update_cmd, "_git_run", fail_fetch)installed = []if failure in {"swap", "late-swap"}:- rename = os.rename-- def fail_second_swap(src, dst):- if str(src).endswith(".hermes-update-staging"):- installed.append(dst)- if len(installed) == (5 if failure == "late-swap" else 2):- raise OSError("locked replacement")- return rename(src, dst)- monkeypatch.setattr(os, "rename", fail_second_swap)+ def failing_nth_swap(move): # root files swap by os.replace, directories by os.rename+ def fail_second_swap(src, dst):+ if str(src).endswith(".hermes-update-staging"):+ installed.append(dst)+ if len(installed) == (5 if failure == "late-swap" else 2):+ raise OSError("locked replacement")+ return move(src, dst)+ return fail_second_swap+ monkeypatch.setattr(os, "rename", failing_nth_swap(os.rename))+ monkeypatch.setattr(os, "replace", failing_nth_swap(os.replace))expected = SystemExitelif failure == "stage":import shutil