@@ -152,7 +152,6 @@ def _test_reading(self, data_to_write, read_and_verify_code):
152152 '"got data %r\\ nexpected %r" % (got, expected))'
153153 )
154154
155- @unittest .expectedFailure # TODO: RUSTPYTHON
156155 def test_readline (self ):
157156 """readline() must handle signals and not lose data."""
158157 self ._test_reading (
@@ -161,7 +160,6 @@ def test_readline(self):
161160 read_method_name = 'readline' ,
162161 expected = b'hello, world!\n ' ))
163162
164- @unittest .expectedFailure # TODO: RUSTPYTHON
165163 def test_readlines (self ):
166164 """readlines() must handle signals and not lose data."""
167165 self ._test_reading (
@@ -170,7 +168,6 @@ def test_readlines(self):
170168 read_method_name = 'readlines' ,
171169 expected = [b'hello\n ' , b'world!\n ' ]))
172170
173- @unittest .expectedFailure # TODO: RUSTPYTHON
174171 def test_readall (self ):
175172 """readall() must handle signals and not lose data."""
176173 self ._test_reading (
@@ -189,6 +186,19 @@ def test_readall(self):
189186class CTestFileIOSignalInterrupt (TestFileIOSignalInterrupt , unittest .TestCase ):
190187 modname = '_io'
191188
189+ # TODO: RUSTPYTHON - _io module uses _pyio internally, signal handling differs
190+ @unittest .expectedFailure
191+ def test_readline (self ):
192+ super ().test_readline ()
193+
194+ @unittest .expectedFailure
195+ def test_readlines (self ):
196+ super ().test_readlines ()
197+
198+ @unittest .expectedFailure
199+ def test_readall (self ):
200+ super ().test_readall ()
201+
192202class PyTestFileIOSignalInterrupt (TestFileIOSignalInterrupt , unittest .TestCase ):
193203 modname = '_pyio'
194204
@@ -200,7 +210,6 @@ def _generate_infile_setup_code(self):
200210 'assert isinstance(infile, io.BufferedReader)' %
201211 self .modname )
202212
203- @unittest .expectedFailure # TODO: RUSTPYTHON
204213 def test_readall (self ):
205214 """BufferedReader.read() must handle signals and not lose data."""
206215 self ._test_reading (
@@ -212,6 +221,19 @@ def test_readall(self):
212221class CTestBufferedIOSignalInterrupt (TestBufferedIOSignalInterrupt , unittest .TestCase ):
213222 modname = '_io'
214223
224+ # TODO: RUSTPYTHON - _io module uses _pyio internally, signal handling differs
225+ @unittest .expectedFailure
226+ def test_readline (self ):
227+ super ().test_readline ()
228+
229+ @unittest .expectedFailure
230+ def test_readlines (self ):
231+ super ().test_readlines ()
232+
233+ @unittest .expectedFailure
234+ def test_readall (self ):
235+ super ().test_readall ()
236+
215237class PyTestBufferedIOSignalInterrupt (TestBufferedIOSignalInterrupt , unittest .TestCase ):
216238 modname = '_pyio'
217239
@@ -224,7 +246,6 @@ def _generate_infile_setup_code(self):
224246 'assert isinstance(infile, io.TextIOWrapper)' %
225247 self .modname )
226248
227- @unittest .expectedFailure # TODO: RUSTPYTHON
228249 def test_readline (self ):
229250 """readline() must handle signals and not lose data."""
230251 self ._test_reading (
@@ -233,7 +254,6 @@ def test_readline(self):
233254 read_method_name = 'readline' ,
234255 expected = 'hello, world!\n ' ))
235256
236- @unittest .expectedFailure # TODO: RUSTPYTHON
237257 def test_readlines (self ):
238258 """readlines() must handle signals and not lose data."""
239259 self ._test_reading (
@@ -242,7 +262,6 @@ def test_readlines(self):
242262 read_method_name = 'readlines' ,
243263 expected = ['hello\n ' , 'world!\n ' ]))
244264
245- @unittest .expectedFailure # TODO: RUSTPYTHON
246265 def test_readall (self ):
247266 """read() must handle signals and not lose data."""
248267 self ._test_reading (
@@ -254,6 +273,19 @@ def test_readall(self):
254273class CTestTextIOSignalInterrupt (TestTextIOSignalInterrupt , unittest .TestCase ):
255274 modname = '_io'
256275
276+ # TODO: RUSTPYTHON - _io module uses _pyio internally, signal handling differs
277+ @unittest .expectedFailure
278+ def test_readline (self ):
279+ super ().test_readline ()
280+
281+ @unittest .expectedFailure
282+ def test_readlines (self ):
283+ super ().test_readlines ()
284+
285+ @unittest .expectedFailure
286+ def test_readall (self ):
287+ super ().test_readall ()
288+
257289class PyTestTextIOSignalInterrupt (TestTextIOSignalInterrupt , unittest .TestCase ):
258290 modname = '_pyio'
259291
0 commit comments