@@ -89,6 +89,7 @@ def write_all(fd, data):
8989
9090# Marginal testing of pty suite. Cannot do extensive 'do or fail' testing
9191# because pty code is not too portable.
92+ @unittest .skipIf (getattr (tty , "tcgetwinsize" , None ) is None , "TODO: RUSTPYTHON; `tty.tcgetwinsize` is required for setUp" )
9293class PtyTest (unittest .TestCase ):
9394 def setUp (self ):
9495 old_sighup = signal .signal (signal .SIGHUP , self .handle_sighup )
@@ -108,7 +109,6 @@ def setUp(self):
108109 def handle_sighup (signum , frame ):
109110 pass
110111
111- @unittest .skip ("TODO: RUSTPYTHON; \" Not runnable. tty.tcgetwinsize\" is required to setUp" )
112112 @expectedFailureIfStdinIsTTY
113113 def test_openpty (self ):
114114 try :
@@ -195,7 +195,6 @@ def test_openpty(self):
195195 s2 = _readline (master_fd )
196196 self .assertEqual (b'For my pet fish, Eric.\n ' , normalize_output (s2 ))
197197
198- @unittest .skip ("TODO: RUSTPYTHON; \" Not runnable. tty.tcgetwinsize\" is required to setUp" )
199198 def test_fork (self ):
200199 debug ("calling pty.fork()" )
201200 pid , master_fd = pty .fork ()
@@ -278,7 +277,6 @@ def test_fork(self):
278277 ##else:
279278 ## raise TestFailed("Read from master_fd did not raise exception")
280279
281- @unittest .skip ("TODO: RUSTPYTHON; AttributeError: module \" tty\" has no attribute \" tcgetwinsize\" " )
282280 def test_master_read (self ):
283281 # XXX(nnorwitz): this test leaks fds when there is an error.
284282 debug ("Calling pty.openpty()" )
@@ -298,7 +296,6 @@ def test_master_read(self):
298296
299297 self .assertEqual (data , b"" )
300298
301- @unittest .skip ("TODO: RUSTPYTHON; AttributeError: module \" tty\" has no attribute \" tcgetwinsize\" " )
302299 def test_spawn_doesnt_hang (self ):
303300 # gh-140482: Do the test in a pty.fork() child to avoid messing
304301 # with the interactive test runner's terminal settings.
0 commit comments