MCPcopy
hub / github.com/pytest-dev/pytest / test_stdin_nulled_by_default

Method test_stdin_nulled_by_default

testing/test_capture.py:1253–1259  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1251 assert sys.stdin is old
1252
1253 def test_stdin_nulled_by_default(self) -> None:
1254 print("XXX this test may well hang instead of crashing")
1255 print("XXX which indicates an error in the underlying capturing")
1256 print("XXX mechanisms")
1257 with self.getcapture():
1258 with pytest.raises(OSError):
1259 sys.stdin.read()
1260
1261
1262class TestTeeStdCapture(TestStdCapture):

Callers

nothing calls this directly

Calls 2

getcaptureMethod · 0.95
readMethod · 0.45

Tested by

no test coverage detected