Files
SeedPass/patch.py
T
google-labs-jules[bot]andPR0M3TH3AN a3b8a91977 fix(test): Skip pty and termios tests on Windows
- Added `pytest.importorskip` calls for `pty` and `termios` to `src/tests/test_ai_tui_agent_harness.py`.
- Formatted `torch/scripts/test-audit/run_python_static_analysis.py` and `torch/scripts/test-audit/run_python_flaky_check.py` using `black`.

Co-authored-by: PR0M3TH3AN <[email protected]>
2026-02-28 02:05:31 +00:00

19 lines
455 B
Python

import re
with open("src/tests/test_ai_tui_agent_harness.py", "r") as f:
content = f.read()
replacement = """import importlib.util
from pathlib import Path
import sys
import pytest
pytest.importorskip("pty")
pytest.importorskip("termios")"""
content = content.replace("import importlib.util\nfrom pathlib import Path\nimport sys\n\nimport pytest", replacement)
with open("src/tests/test_ai_tui_agent_harness.py", "w") as f:
f.write(content)