관리-도구
편집 파일: test_weakref.cpython-38.pyc
U �gs � @ s8 d dl Z d dlZd dlZddlmZ G dd� de�ZdS )� N� )�TestCasec @ s$ e Zd Zdd� Zdd� Zdd� ZdS )�WeakRefTestsc C s. dd� }t �|� �}t�� | �|� d � d S )Nc S s t � dd� �} | �� | S )Nc S s d S �N� r r r �K/opt/hc_python/lib64/python3.8/site-packages/greenlet/tests/test_weakref.py�<lambda> � zHWeakRefTests.test_dead_weakref.<locals>._dead_greenlet.<locals>.<lambda>)�greenlet�switch)�gr r r �_dead_greenlet s z6WeakRefTests.test_dead_weakref.<locals>._dead_greenlet)�weakref�ref�gc�collect�assertEqual)�selfr �or r r �test_dead_weakref s zWeakRefTests.test_dead_weakrefc C s( t �t�� �}t�� | �|� d � d S r )r r r r r r )r r r r r �test_inactive_weakref s z"WeakRefTests.test_inactive_weakrefc sT g �� �fdd�}t � |�� � �� t � dd� � �}t�|�� d }| ��d g� d S )Nc s&