@@ -101,11 +101,6 @@ def load_tests(loader, standard_tests, pattern):
101101 test .test_io .PyMiscIOTest ('test_warn_on_dealloc_fd' ), # AssertionError: ResourceWarning not triggered
102102 ]
103103
104- if is_mono :
105- failing_tests += [
106- test .test_io .CBufferedRandomTest ('test_destructor' ), # IndexError: index out of range: 0
107- ]
108-
109104 skip_tests = [
110105 test .test_io .CBufferedWriterTest ('test_override_destructor' ), # StackOverflowException
111106 test .test_io .CBufferedRandomTest ('test_override_destructor' ), # StackOverflowException
@@ -144,6 +139,31 @@ def load_tests(loader, standard_tests, pattern):
144139 test .test_io .PyMiscIOTest ('test_attributes' ), # AssertionError: 'wb+' != 'rb+'
145140 ]
146141
142+ if is_mono :
143+ skip_tests += [
144+ # On Mono, gc.collect() may return before collection is finished making some tests unreliable
145+ test .test_io .CBufferedRandomTest ('test_destructor' ),
146+ test .test_io .CBufferedWriterTest ('test_destructor' ),
147+ test .test_io .PyBufferedWriterTest ('test_destructor' ),
148+ test .test_io .PyBufferedRandomTest ('test_destructor' ),
149+ test .test_io .PyBufferedReaderTest ('test_override_destructor' ),
150+ test .test_io .PyBufferedWriterTest ('test_override_destructor' ),
151+ test .test_io .PyBufferedRandomTest ('test_override_destructor' ),
152+
153+ test .test_io .CTextIOWrapperTest ('test_destructor' ),
154+ test .test_io .CIOTest ('test_IOBase_finalize' ),
155+
156+ test .test_io .PyTextIOWrapperTest ('test_destructor' ),
157+ test .test_io .PyTextIOWrapperTest ('test_override_destructor' ),
158+ test .test_io .PyIOTest ('test_RawIOBase_destructor' ),
159+ test .test_io .PyIOTest ('test_BufferedIOBase_destructor' ),
160+ test .test_io .PyIOTest ('test_IOBase_destructor' ),
161+ test .test_io .PyIOTest ('test_TextIOBase_destructor' ),
162+
163+ test .test_io .CMiscIOTest ('test_blockingioerror' ),
164+ test .test_io .PyMiscIOTest ('test_blockingioerror' ),
165+ ]
166+
147167 return generate_suite (tests , failing_tests , skip_tests )
148168
149169 else :
0 commit comments