test(gateway): drop source-reading guard test from #71671 salvage

Source-regex tests are banned (AGENTS.md 'Never read source code in
tests') — keep only the behavioral regression test.
This commit is contained in:
teknium1 2026-07-26 16:40:42 -07:00 committed by Teknium
parent 12fdaeaf1a
commit 0f554ce19e
2 changed files with 1 additions and 13 deletions

View file

@ -0,0 +1 @@
hereicq

View file

@ -3,7 +3,6 @@
from __future__ import annotations
import faulthandler
import os
import sys
import pytest
@ -33,15 +32,3 @@ def test_faulthandler_enable_falls_back_when_stderr_is_none(tmp_path):
sys.stderr = real_stderr
if was_enabled:
faulthandler.enable()
def test_gateway_run_keeps_faulthandler_guard():
src = os.path.join(
os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__)))),
"gateway", "run.py",
)
with open(src, encoding="utf-8") as f:
text = f.read()
assert "try:\n faulthandler.enable()\n except (RuntimeError, ValueError, OSError):" in text, (
"gateway/run.py must keep the try/except guard around faulthandler.enable() (see #71671)"
)