import subprocess import sys import os def verify_phase_2(): print("Verifying Phase 2: Text Input & Control Undo/Redo...") # Run the simulation test result = subprocess.run( ["uv", "run", "pytest", "tests/test_undo_redo_sim.py"], capture_output=True, text=True ) if result.returncode == 0: print("Phase 2 verification PASSED.") else: print("Phase 2 verification FAILED.") print(result.stdout) print(result.stderr) sys.exit(1) if __name__ == "__main__": verify_phase_2()