MCPcopy Create free account
hub / github.com/apache/arrow / test_signal_refcycle

Function test_signal_refcycle

python/pyarrow/tests/test_util.py:199–212  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

197
198
199def test_signal_refcycle():
200 # Test possible workaround for https://bugs.python.org/issue42248
201 with disabled_gc():
202 wr = exhibit_signal_refcycle()
203 if wr() is None:
204 pytest.skip(
205 "Python version does not have the bug we're testing for")
206
207 gc.collect()
208 with disabled_gc():
209 wr = exhibit_signal_refcycle()
210 assert wr() is not None
211 _break_traceback_cycle_from_frame(sys._getframe(0))
212 assert wr() is None
213
214
215@pytest.mark.skipif(sys.platform != "win32",

Callers

nothing calls this directly

Calls 3

disabled_gcFunction · 0.90
exhibit_signal_refcycleFunction · 0.85

Tested by

no test coverage detected