Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
mark test failures
  • Loading branch information
youknowone committed Feb 1, 2026
commit 9a9426ee73921d1fa944f7bde29f5b7da56dd624
2 changes: 2 additions & 0 deletions Lib/test/test_asyncgen.py
Original file line number Diff line number Diff line change
Expand Up @@ -1026,6 +1026,7 @@ async def run():
fut.cancel()
self.loop.run_until_complete(asyncio.sleep(0.01))

@unittest.expectedFailure # TODO: RUSTPYTHON; gc_collect doesn't finalize async generators
def test_async_gen_asyncio_gc_aclose_09(self):
DONE = 0

Expand Down Expand Up @@ -1512,6 +1513,7 @@ async def main():
self.assertIn('an error occurred during closing of asynchronous generator',
message['message'])

@unittest.expectedFailure # TODO: RUSTPYTHON; gc_collect doesn't finalize async generators, different cleanup path
def test_async_gen_asyncio_shutdown_exception_02(self):
messages = []

Expand Down
4 changes: 2 additions & 2 deletions Lib/test/test_asyncio/test_free_threading.py
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ def tearDown(self):
def factory(self, loop, coro, **kwargs):
return asyncio.tasks._PyTask(coro, loop=loop, **kwargs)

@unittest.expectedFailure # TODO: RUSTPYTHON; AssertionError: <Task finished name='Task-7322' coro=<TestFreeThreading.test_task_different_thread_finalized.<locals>.func() done, defined at /Users/al03219714/Projects/RustPython2/crates/pylib/Lib/test/test_asyncio/test_free_threading.py:101> result=None> is not None
@unittest.expectedFailure # TODO: RUSTPYTHON; GC weak reference timing issue
def test_task_different_thread_finalized(self):
return super().test_task_different_thread_finalized()

Expand Down Expand Up @@ -228,7 +228,7 @@ class TestEagerPyFreeThreading(TestPyFreeThreading):
def factory(self, loop, coro, eager_start=True, **kwargs):
return asyncio.tasks._PyTask(coro, loop=loop, **kwargs, eager_start=eager_start)

@unittest.expectedFailure # TODO: RUSTPYTHON; AssertionError: <Task finished name='Task-5240' coro=<TestFreeThreading.test_task_different_thread_finalized.<locals>.func() done, defined at /Users/al03219714/Projects/RustPython2/crates/pylib/Lib/test/test_asyncio/test_free_threading.py:101> result=None> is not None
@unittest.expectedFailure # TODO: RUSTPYTHON; GC weak reference timing issue
def test_task_different_thread_finalized(self):
return super().test_task_different_thread_finalized()

Expand Down
2 changes: 1 addition & 1 deletion Lib/test/test_asyncio/test_streams.py
Original file line number Diff line number Diff line change
Expand Up @@ -1078,7 +1078,7 @@ def test_eof_feed_when_closing_writer(self):

self.assertEqual(messages, [])

@unittest.expectedFailure # TODO: RUSTPYTHON; AssertionError: 0 != 1
@unittest.expectedFailure # TODO: RUSTPYTHON; GC finalization timing issue
def test_unclosed_resource_warnings(self):
async def inner(httpd):
rd, wr = await asyncio.open_connection(*httpd.address)
Expand Down
1 change: 1 addition & 0 deletions Lib/test/test_concurrent_futures/test_as_completed.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ def test_duplicate_futures(self):
]
self.assertEqual(len(completed), 1)

@unittest.expectedFailure # TODO: RUSTPYTHON; GC weak reference not collected
def test_free_reference_yielded_future(self):
# Issue #14406: Generator should not keep references
# to finished futures.
Expand Down
2 changes: 2 additions & 0 deletions Lib/test/test_concurrent_futures/test_init.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,11 @@ def _test(self, test_class):

self.assertEqual(_resource_tracker._exitcode, 0)

@unittest.expectedFailure # TODO: RUSTPYTHON; resource tracker exit code mismatch
def test_spawn(self):
self._test(ProcessPoolSpawnFailingInitializerTest)

@unittest.expectedFailure # TODO: RUSTPYTHON; resource tracker exit code mismatch
@support.skip_if_sanitizer("TSAN doesn't support threads after fork", thread=True)
def test_forkserver(self):
self._test(ProcessPoolForkserverFailingInitializerTest)
Expand Down
4 changes: 4 additions & 0 deletions Lib/test/test_copy.py
Original file line number Diff line number Diff line change
Expand Up @@ -837,12 +837,15 @@ class C(object):
v[x] = y
self.assertNotIn(x, u)

@unittest.expectedFailure # TODO: RUSTPYTHON; weakref callback not fired immediately by gc_collect
def test_copy_weakkeydict(self):
self._check_copy_weakdict(weakref.WeakKeyDictionary)

@unittest.expectedFailure # TODO: RUSTPYTHON; weakref callback not fired immediately by gc_collect
def test_copy_weakvaluedict(self):
self._check_copy_weakdict(weakref.WeakValueDictionary)

@unittest.expectedFailure # TODO: RUSTPYTHON; weakref callback not fired immediately by gc_collect
def test_deepcopy_weakkeydict(self):
class C(object):
def __init__(self, i):
Expand All @@ -863,6 +866,7 @@ def __init__(self, i):
support.gc_collect() # For PyPy or other GCs.
self.assertEqual(len(v), 1)

@unittest.expectedFailure # TODO: RUSTPYTHON; weakref callback not fired immediately by gc_collect
def test_deepcopy_weakvaluedict(self):
class C(object):
def __init__(self, i):
Expand Down
1 change: 1 addition & 0 deletions Lib/test/test_coroutines.py
Original file line number Diff line number Diff line change
Expand Up @@ -1668,6 +1668,7 @@ async def foo():

self.assertEqual(sys.getrefcount(aiter), refs_before)

@unittest.expectedFailure # TODO: RUSTPYTHON; refcount leak in async for/with
def test_for_6(self):
I = 0

Expand Down
1 change: 1 addition & 0 deletions Lib/test/test_exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -1076,6 +1076,7 @@ def do_close(g):
g.close()
self._check_generator_cleanup_exc_state(do_close)

@unittest.expectedFailure # TODO: RUSTPYTHON; GC generator cleanup timing
def test_generator_del_cleanup_exc_state(self):
def do_del(g):
g = None
Expand Down
4 changes: 2 additions & 2 deletions Lib/test/test_subprocess.py
Original file line number Diff line number Diff line change
Expand Up @@ -2274,14 +2274,12 @@ def test_group_error(self):
with self.assertRaises(ValueError):
subprocess.check_call(ZERO_RETURN_CMD, group=65535)

@unittest.expectedFailure # TODO: RUSTPYTHON; observed gids do not match expected gids
@unittest.skipUnless(hasattr(os, 'setgroups'), 'no setgroups() on platform')
def test_extra_groups(self):
gid = os.getegid()
group_list = [65534 if gid != 65534 else 65533]
self._test_extra_groups_impl(gid=gid, group_list=group_list)

@unittest.expectedFailure # TODO: RUSTPYTHON
@unittest.skipUnless(hasattr(os, 'setgroups'), 'no setgroups() on platform')
def test_extra_groups_empty_list(self):
self._test_extra_groups_impl(gid=os.getegid(), group_list=[])
Expand Down Expand Up @@ -3284,6 +3282,7 @@ def test_select_unbuffered(self):
finally:
p.wait()

@unittest.expectedFailure # TODO: RUSTPYTHON; GC Popen.__del__ timing
def test_zombie_fast_process_del(self):
# Issue #12650: on Unix, if Popen.__del__() was called before the
# process exited, it wouldn't be added to subprocess._active, and would
Expand All @@ -3308,6 +3307,7 @@ def test_zombie_fast_process_del(self):
# check that p is in the active processes list
self.assertIn(ident, [id(o) for o in subprocess._active])

@unittest.expectedFailure # TODO: RUSTPYTHON; GC Popen.__del__ timing
def test_leak_fast_process_del_killed(self):
# Issue #12650: on Unix, if Popen.__del__() was called before the
# process exited, and the process got killed by a signal, it would never
Expand Down
1 change: 0 additions & 1 deletion Lib/test/test_unittest/test_async_case.py
Original file line number Diff line number Diff line change
Expand Up @@ -475,7 +475,6 @@ async def cleanup(self, fut):
test.doCleanups()
self.assertEqual(events, ['asyncSetUp', 'test', 'cleanup'])

@unittest.expectedFailure
def test_setup_get_event_loop(self):
# See https://github.com/python/cpython/issues/95736
# Make sure the default event loop is not used
Expand Down
2 changes: 2 additions & 0 deletions Lib/test/test_unittest/test_suite.py
Original file line number Diff line number Diff line change
Expand Up @@ -374,9 +374,11 @@ def test_nothing(self):
self.assertEqual(suite._tests, [None])
self.assertIsNone(wref())

@unittest.expectedFailure # TODO: RUSTPYTHON; GC test not collected after run
def test_garbage_collect_test_after_run_BaseTestSuite(self):
self.assert_garbage_collect_test_after_run(unittest.BaseTestSuite)

@unittest.expectedFailure # TODO: RUSTPYTHON; GC test not collected after run
def test_garbage_collect_test_after_run_TestSuite(self):
self.assert_garbage_collect_test_after_run(unittest.TestSuite)

Expand Down
4 changes: 4 additions & 0 deletions Lib/test/test_weakref.py
Original file line number Diff line number Diff line change
Expand Up @@ -1368,6 +1368,7 @@ def test_weak_keyed_len_race(self):
def test_weak_valued_len_race(self):
self.check_len_race(weakref.WeakValueDictionary, lambda k: (1, k))

@unittest.expectedFailure # TODO: RUSTPYTHON; weakref callback not fired immediately by gc_collect
def test_weak_values(self):
#
# This exercises d.copy(), d.items(), d[], del d[], len(d).
Expand Down Expand Up @@ -1400,6 +1401,7 @@ def test_weak_values(self):
gc_collect() # For PyPy or other GCs.
self.assertRaises(KeyError, dict.__getitem__, 2)

@unittest.expectedFailure # TODO: RUSTPYTHON; weakref callback not fired immediately by gc_collect
def test_weak_keys(self):
#
# This exercises d.copy(), d.items(), d[] = v, d[], del d[],
Expand Down Expand Up @@ -1765,6 +1767,7 @@ def test_weak_valued_dict_update(self):
self.assertEqual(list(d.keys()), [kw])
self.assertEqual(d[kw], o)

@unittest.expectedFailure # TODO: RUSTPYTHON; weakref callback not fired immediately by gc_collect
def test_weak_valued_union_operators(self):
a = C()
b = C()
Expand Down Expand Up @@ -1817,6 +1820,7 @@ def test_weak_keyed_delitem(self):
self.assertEqual(len(d), 1)
self.assertEqual(list(d.keys()), [o2])

@unittest.expectedFailure # TODO: RUSTPYTHON; weakref callback not fired immediately by gc_collect
def test_weak_keyed_union_operators(self):
o1 = C()
o2 = C()
Expand Down
3 changes: 3 additions & 0 deletions Lib/test/test_weakset.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ def test_contains(self):
support.gc_collect() # For PyPy or other GCs.
self.assertNotIn(ustr('F'), self.fs)

@unittest.expectedFailure # TODO: RUSTPYTHON; GC weak reference not collected
def test_union(self):
u = self.s.union(self.items2)
for c in self.letters:
Expand All @@ -91,6 +92,7 @@ def test_or(self):
self.assertEqual(self.s | set(self.items2), i)
self.assertEqual(self.s | frozenset(self.items2), i)

@unittest.expectedFailure # TODO: RUSTPYTHON; GC weak reference not collected
def test_intersection(self):
s = WeakSet(self.letters)
i = s.intersection(self.items2)
Expand Down Expand Up @@ -128,6 +130,7 @@ def test_sub(self):
self.assertEqual(self.s - set(self.items2), i)
self.assertEqual(self.s - frozenset(self.items2), i)

@unittest.expectedFailure # TODO: RUSTPYTHON; GC weak reference not collected
def test_symmetric_difference(self):
i = self.s.symmetric_difference(self.items2)
for c in self.letters:
Expand Down