Viewing File: /opt/hc_python/lib/python3.12/site-packages/greenlet/tests/__pycache__/test_weakref.cpython-312.pyc

�

i0is��>�ddlZddlZddlZddlmZGd�de�Zy)�N�)�TestCasec��eZdZd�Zd�Zd�Zy)�WeakRefTestsc��d�}tj|��}tj�|j	|�d�y)Nc�R�tjd��}|j�|S)Nc��y�N�r��L/opt/hc_python/lib64/python3.12/site-packages/greenlet/tests/test_weakref.py�<lambda>zHWeakRefTests.test_dead_weakref.<locals>._dead_greenlet.<locals>.<lambda>s��$r)�greenlet�switch)�gs r
�_dead_greenletz6WeakRefTests.test_dead_weakref.<locals>._dead_greenlet
s ���!�!�,�/�A�
�H�H�J��Hr)�weakref�ref�gc�collect�assertEqual)�selfr�os   r
�test_dead_weakrefzWeakRefTests.test_dead_weakref	s5��	�
�K�K��(�)��
�
�
�������d�#rc��tjtj��}tj�|j|�d�yr
)rrrrrr)rrs  r
�test_inactive_weakrefz"WeakRefTests.test_inactive_weakrefs4���K�K��)�)�+�,��
�
�
�������d�#rc�����g���fd�}tj|���j�tjd���}tj|��d}|j	�dg�y)Nc����	tj�jj��j	���y#�j	���wxYwr
)r�
getcurrent�parentr�append)r�seens��r
�workerz1WeakRefTests.test_dealloc_weakref.<locals>.workers@���
!��#�#�%�,�,�3�3�5����A�C� �����A�C� �s�,A�Ac��yr
rrrr
rz3WeakRefTests.test_dealloc_weakref.<locals>.<lambda> s��tr)rrrrr)rr#�g2rr"s   @@r
�test_dealloc_weakrefz!WeakRefTests.test_dealloc_weakrefs^�����	!�

���f�%��	���
�
�
�
�|�Q�
/���K�K��O��
�������v�&rN)�__name__�
__module__�__qualname__rrr&rrr
rrs��$�$�
'rr)rrr�rrrrr
�<module>r+s��	����'�8�'r
Back to Directory File Manager