Sindbad~EG File Manager

Current Path : /usr/local/lib/python3.11/test/__pycache__/
Upload File :
Current File : //usr/local/lib/python3.11/test/__pycache__/test_copy.cpython-311.opt-2.pyc

�

SԚgj����	ddlZddlZddlZddlZddlmZmZmZmZm	Z	m
Z
ddlZddlm
Z
eeeefZe	e
fZeezZGd�dej��Zd�Zedkrej��dSdS)�N)�le�lt�ge�gt�eq�ne)�supportc���eZdZd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�Zd�Z
d�Zd
�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z d�Z!d �Z"d!�Z#d"�Z$d#�Z%d$�Z&d%�Z'd&�Z(d'�Z)d(�Z*d)�Z+d*�Z,d+�Z-d,�Z.d-�Z/d.�Z0d/�Z1d0�Z2d1�Z3d2�Z4d3�Z5d4�Z6d5�Z7d6�Z8d7�Z9d8�Z:d9�Z;d:�Z<d;�Z=d<�Z>d=�Z?d>�Z@d?�ZAd@�ZBdA�ZCdB�ZDdC�ZEdD�ZFdE�ZGdF�ZHdG�ZIdH�ZJdI�ZKdJ�ZLdK�ZMdL�ZNdM�ZOdN�ZPdOS)P�TestCopyc��|�tjtj��|�ttjt����dS�N)�assertIs�copy�Error�error�
assertTrue�
issubclass�	Exception��selfs �+/usr/local/lib/python3.11/test/test_copy.py�test_exceptionszTestCopy.test_exceptionss>���
�
�d�j�$�*�-�-�-����
�4�:�y�9�9�:�:�:�:�:�c�^�d}tj|��}|�||��dS�N�*)r�assertEqual�r�x�ys   r�test_copy_basiczTestCopy.test_copy_basics0�����I�a�L�L������A�����rc����G�fd�dt����d��}tj|��}|�|j|j��|�|j|j��dS)Nc� ��eZdZd�Z�fd�ZdS)�"TestCopy.test_copy_copy.<locals>.Cc��||_dSr
��foo�rr's  r�__init__z+TestCopy.test_copy_copy.<locals>.C.__init__!�
������rc�$���|j��Sr
r&�r�Cs �r�__copy__z+TestCopy.test_copy_copy.<locals>.C.__copy__#�����q���{�{�"rN)�__name__�
__module__�__qualname__r)r.�r-s�rr-r$ s=�������
�
�
�
#�
#�
#�
#�
#�
#�
#rr-r)�objectrr�	__class__r'�rrr r-s   @r�test_copy_copyzTestCopy.test_copy_copys����	#�	#�	#�	#�	#�	#�	#��	#�	#�	#�

�A�b�E�E���I�a�L�L�������a�k�2�2�2��������&�&�&�&�&rc���Gd�dt����fd�}�d��}|�ttj|��t	j�|���tj|��}|�||��|�t|�����|�|j	|j	��dS)Nc��eZdZd�ZdS)�&TestCopy.test_copy_registry.<locals>.Cc�H�t�|��}||_|Sr
�r4�__new__r'��clsr'�objs   rr=z.TestCopy.test_copy_registry.<locals>.C.__new__,����n�n�S�)�)������
rN�r0r1r2r=�rrr-r:+�#������
�
�
�
�
rr-c����|jffSr
r&�r@r-s �r�pickle_Cz-TestCopy.test_copy_registry.<locals>.pickle_C0�������z�?�"rr)
r4�assertRaises�	TypeErrorr�copyreg�pickle�assertIsNotr�typer'�rrGrr r-s    @r�test_copy_registryzTestCopy.test_copy_registry*s����	�	�	�	�	��	�	�	�
	#�	#�	#�	#�	#�
�A�b�E�E�����)�T�Y��2�2�2���q�(�A�&�&�&��I�a�L�L������A��������a���!�$�$�$��������&�&�&�&�&rc����G�fd�dt��}g�|��}tj|��}|�||��|��dg��dS)Nc� ��eZdZ�fd�Zd�ZdS)�'TestCopy.test_copy_reduce_ex.<locals>.Cc�2����d��dS�N����append�r�proto�cs  �r�
__reduce_ex__z5TestCopy.test_copy_reduce_ex.<locals>.C.__reduce_ex__<������������rrc�0�|�d��dS�Nzshouldn't call this��failrs r�
__reduce__z2TestCopy.test_copy_reduce_ex.<locals>.C.__reduce__?����	�	�/�0�0�0�0�0rN�r0r1r2r]rc�r\s�rr-rS;�=�������
�
�
�
�
�
1�
1�
1�
1�
1rr-rV�r4rrr�rr-rr r\s    @r�test_copy_reduce_exzTestCopy.test_copy_reduce_ex:s����	1�	1�	1�	1�	1�	1�	1��	1�	1�	1�
��
�A�C�C���I�a�L�L���
�
�a���������Q�C� � � � � rc����G�fd�dt��}g�|��}tj|��}|�||��|��dg��dS)Nc���eZdZ�fd�ZdS)�$TestCopy.test_copy_reduce.<locals>.Cc�2����d��dSrUrX�rr\s �rrcz/TestCopy.test_copy_reduce.<locals>.C.__reduce__Ir^rN�r0r1r2rcrfs�rr-rmH�.�������
�
�
�
�
�
�
rr-rVrhris    @r�test_copy_reducezTestCopy.test_copy_reduceGs����	�	�	�	�	�	�	��	�	�	�
��
�A�C�C���I�a�L�L���
�
�a���������Q�C� � � � � rc��Gd�dt��}|��}|�tjtj|��dS)Nc��eZdZd�ZdS)�"TestCopy.test_copy_cant.<locals>.Cc��|�d��rt|���t�||��S�N�__reduce��
startswith�AttributeErrorr4�__getattribute__�r�names  rr|z3TestCopy.test_copy_cant.<locals>.C.__getattribute__T�:���?�?�:�.�.�/�(��.�.�.��.�.�t�T�:�:�:rN�r0r1r2r|rCrrr-ruS�#������
;�
;�
;�
;�
;rr-)r4rIrr�rr-rs   r�test_copy_cantzTestCopy.test_copy_cantRs[��	;�	;�	;�	;�	;��	;�	;�	;�

�A�C�C�����$�*�d�i��3�3�3�3�3rc��Gd�d��}d�}Gd�dtj���}ddtdd	d
zddd
ddd|jdt	td����td��t
ddd	��|t|t��g}|D]*}|�	tj
|��|���+dS)Nc��eZdZdS)�+TestCopy.test_copy_atomic.<locals>.NewStyleN�r0r1r2rCrr�NewStyler�^��������Drr�c��dSr
rCrCrr�fz$TestCopy.test_copy_atomic.<locals>.f`����Drc��eZdZdS)�0TestCopy.test_copy_atomic.<locals>.WithMetaclassNr�rCrr�
WithMetaclassr�br�rr���	metaclass.r��d���Q�	@TF��?�hello�helloሴsworld��
rV)�abc�ABCMeta�NotImplemented�__code__�bytes�range�slice�max�propertyrr)rr�r�r��testsrs      r�test_copy_atomiczTestCopy.test_copy_atomic]s��	�	�	�	�	�	�	�	�	�	�	�	�	�	�	�	�c�k�	�	�	�	��s�N��Q��V�T�4����-����5��s���,�,�e�B�i�i��q�"�a����3�
�x�z�z�	;��
�	+�	+�A��M�M�$�)�A�,�,��*�*�*�*�	+�	+rc��gd�}tj|��}|�||��|�||��g}tj|��}|�||��|�||��dS)N�rVr���rrrMrs   r�test_copy_listzTestCopy.test_copy_listls����I�I���I�a�L�L������A��������A�������I�a�L�L������A��������A�����rc�
�d}|�tj|��|��d}|�tj|��|��dddgf}|�tj|��|��dS)Nr�rCrVr�r�)rr�rrs  r�test_copy_tuplezTestCopy.test_copy_tuplevss�����
�
�d�i��l�l�A�&�&�&����
�
�d�i��l�l�A�&�&�&�
��1�b�M���
�
�d�i��l�l�A�&�&�&�&�&rc��ddd�}tj|��}|�||��|�||��i}tj|��}|�||��|�||��dS)NrVr��r'�barr�rs   r�test_copy_dictzTestCopy.test_copy_dict~s����a� � ���I�a�L�L������A��������A�������I�a�L�L������A��������A�����rc�*�hd�}tj|��}|�||��|�||��t��}tj|��}|�||��|�||��dS�N>rVr�r�)rrrM�setrs   r�
test_copy_setzTestCopy.test_copy_set�s����I�I���I�a�L�L������A��������A�����E�E���I�a�L�L������A��������A�����rc���thd���}|�tj|��|��t��}|�tj|��|��dSr�)�	frozensetrrr�s  r�test_copy_frozensetzTestCopy.test_copy_frozenset�sZ���i�i�i� � ���
�
�d�i��l�l�A�&�&�&��K�K���
�
�d�i��l�l�A�&�&�&�&�&rc�@�td��}tj|��}|�||��|�||��t��}tj|��}|�||��|�||��dS)Nsabc)�	bytearrayrrrMrs   r�test_copy_bytearrayzTestCopy.test_copy_bytearray�s����f�����I�a�L�L������A��������A�����K�K���I�a�L�L������A��������A�����rc��Gd�d��}|d��}|�tj|��|��dS)Nc��eZdZd�Zd�ZdS)�*TestCopy.test_copy_inst_vanilla.<locals>.Cc��||_dSr
r&r(s  rr)z3TestCopy.test_copy_inst_vanilla.<locals>.C.__init__�r*rc�"�|j|jkSr
r&�r�others  r�__eq__z1TestCopy.test_copy_inst_vanilla.<locals>.C.__eq__�����x�5�9�,�,rN�r0r1r2r)r�rCrrr-r���2������
�
�
�
-�
-�
-�
-�
-rr-r�rrr�s   r�test_copy_inst_vanillazTestCopy.test_copy_inst_vanilla�s]��	-�	-�	-�	-�	-�	-�	-�	-�

�A�b�E�E�������1���q�)�)�)�)�)rc���G�fd�d����d��}|�tj|��|��dS)Nc�&��eZdZd�Z�fd�Zd�ZdS)�'TestCopy.test_copy_inst_copy.<locals>.Cc��||_dSr
r&r(s  rr)z0TestCopy.test_copy_inst_copy.<locals>.C.__init__�r*rc�$���|j��Sr
r&r,s �rr.z0TestCopy.test_copy_inst_copy.<locals>.C.__copy__�r/rc�"�|j|jkSr
r&r�s  rr�z.TestCopy.test_copy_inst_copy.<locals>.C.__eq__�r�rN)r0r1r2r)r.r�r3s�rr-r��sL�������
�
�
�
#�
#�
#�
#�
#�
-�
-�
-�
-�
-rr-rr��rrr-s  @r�test_copy_inst_copyzTestCopy.test_copy_inst_copy�sh���	-�	-�	-�	-�	-�	-�	-�	-�	-�	-�
�A�b�E�E�������1���q�)�)�)�)�)rc��Gd�d��}|d��}|�tj|��|��dS)Nc� �eZdZd�Zd�Zd�ZdS)�.TestCopy.test_copy_inst_getinitargs.<locals>.Cc��||_dSr
r&r(s  rr)z7TestCopy.test_copy_inst_getinitargs.<locals>.C.__init__�r*rc��|jfSr
r&rs r�__getinitargs__z>TestCopy.test_copy_inst_getinitargs.<locals>.C.__getinitargs__������{�"rc�"�|j|jkSr
r&r�s  rr�z5TestCopy.test_copy_inst_getinitargs.<locals>.C.__eq__�r�rN�r0r1r2r)r�r�rCrrr-r���A������
�
�
�
#�
#�
#�
-�
-�
-�
-�
-rr-rr�r�s   r�test_copy_inst_getinitargsz#TestCopy.test_copy_inst_getinitargs��]��	-�	-�	-�	-�	-�	-�	-�	-�
�A�b�E�E�������1���q�)�)�)�)�)rc�.�Gd�dt��}|d��}tj|��}|�||��|�||��|�||��|�|j|j��dS)Nc� �eZdZd�Zd�Zd�ZdS)�-TestCopy.test_copy_inst_getnewargs.<locals>.Cc�H�t�|��}||_|Sr
��intr=r'�r?r'rs   rr=z5TestCopy.test_copy_inst_getnewargs.<locals>.C.__new__�����{�{�3�'�'������rc��|jfSr
r&rs r�__getnewargs__z<TestCopy.test_copy_inst_getnewargs.<locals>.C.__getnewargs__�����x�y� rc�"�|j|jkSr
r&r�s  rr�z4TestCopy.test_copy_inst_getnewargs.<locals>.C.__eq__�r�rN�r0r1r2r=r�r�rCrrr-r���A������
�
�
�
!�
!�
!�
-�
-�
-�
-�
-rr-r�r�r�assertIsInstancerrMr'�rr-rr s    r�test_copy_inst_getnewargsz"TestCopy.test_copy_inst_getnewargs�s���	-�	-�	-�	-�	-��	-�	-�	-�
�A�b�E�E���I�a�L�L�����a��#�#�#�����A��������A�����������&�&�&�&�&rc�0�Gd�dt��}|d���}tj|��}|�||��|�||��|�||��|�|j|j��dS)Nc� �eZdZd�Zd�Zd�ZdS)�0TestCopy.test_copy_inst_getnewargs_ex.<locals>.Cc�H�t�|��}||_|Sr
r�r�s   rr=z8TestCopy.test_copy_inst_getnewargs_ex.<locals>.C.__new__�r�rc��dd|jifS�NrCr'r&rs r�__getnewargs_ex__zBTestCopy.test_copy_inst_getnewargs_ex.<locals>.C.__getnewargs_ex__�����E�4�8�,�,�,rc�"�|j|jkSr
r&r�s  rr�z7TestCopy.test_copy_inst_getnewargs_ex.<locals>.C.__eq__�r�rN�r0r1r2r=r�r�rCrrr-r���A������
�
�
�
-�
-�
-�
-�
-�
-�
-�
-rr-rr&r�r�s    r�test_copy_inst_getnewargs_exz%TestCopy.test_copy_inst_getnewargs_ex�s���	-�	-�	-�	-�	-��	-�	-�	-�
�A�"�I�I�I���I�a�L�L�����a��#�#�#�����A��������A�����������&�&�&�&�&rc��Gd�d��}|d��}|�tj|��|��dS)Nc� �eZdZd�Zd�Zd�ZdS)�+TestCopy.test_copy_inst_getstate.<locals>.Cc��||_dSr
r&r(s  rr)z4TestCopy.test_copy_inst_getstate.<locals>.C.__init__�r*rc��d|jiS�Nr'r&rs r�__getstate__z8TestCopy.test_copy_inst_getstate.<locals>.C.__getstate__�����t�x�(�(rc�"�|j|jkSr
r&r�s  rr�z2TestCopy.test_copy_inst_getstate.<locals>.C.__eq__�r�rN�r0r1r2r)rr�rCrrr-r���A������
�
�
�
)�
)�
)�
-�
-�
-�
-�
-rr-rr�r�s   r�test_copy_inst_getstatez TestCopy.test_copy_inst_getstate�r�rc��Gd�d��}|d��}|�tj|��|��dS)Nc� �eZdZd�Zd�Zd�ZdS)�+TestCopy.test_copy_inst_setstate.<locals>.Cc��||_dSr
r&r(s  rr)z4TestCopy.test_copy_inst_setstate.<locals>.C.__init__�r*rc� �|d|_dSr�r&�r�states  r�__setstate__z8TestCopy.test_copy_inst_setstate.<locals>.C.__setstate__���� ��<����rc�"�|j|jkSr
r&r�s  rr�z2TestCopy.test_copy_inst_setstate.<locals>.C.__eq__�r�rN�r0r1r2r)r
r�rCrrr-r��A������
�
�
�
(�
(�
(�
-�
-�
-�
-�
-rr-rr�r�s   r�test_copy_inst_setstatez TestCopy.test_copy_inst_setstate�r�rc���Gd�d��}|d��}|�tj|��|��|d��}|�tj|��|��dS)Nc�&�eZdZd�Zd�Zd�Zd�ZdS)�4TestCopy.test_copy_inst_getstate_setstate.<locals>.Cc��||_dSr
r&r(s  rr)z=TestCopy.test_copy_inst_getstate_setstate.<locals>.C.__init__�r*rc��|jSr
r&rs rrzATestCopy.test_copy_inst_getstate_setstate.<locals>.C.__getstate__��	���x�rc��||_dSr
r&rs  rr
zATestCopy.test_copy_inst_getstate_setstate.<locals>.C.__setstate__��
�� ����rc�"�|j|jkSr
r&r�s  rr�z;TestCopy.test_copy_inst_getstate_setstate.<locals>.C.__eq__r�rN�r0r1r2r)rr
r�rCrrr-r��P������
�
�
�
 �
 �
 �
!�
!�
!�
-�
-�
-�
-�
-rr-rgr�r�s   r� test_copy_inst_getstate_setstatez)TestCopy.test_copy_inst_getstate_setstate�s���	-�	-�	-�	-�	-�	-�	-�	-�
�A�b�E�E�������1���q�)�)�)�
�A�c�F�F�������1���q�)�)�)�)�)rc�^�d}tj|��}|�||��dSr)r�deepcopyrrs   r�test_deepcopy_basiczTestCopy.test_deepcopy_basics2�����M�!��������A�����rc��g}||g}tj|��}|�||��|�||��|�|d|d��|�|d|d��dS�NrrV)rr rrMrrs   r�test_deepcopy_memozTestCopy.test_deepcopy_memos���
��
��F���M�!��������A��������A��������1��q��t�$�$�$��
�
�a��d�A�a�D�!�!�!�!�!rc��Gd�dt��}Gd�d|���}|�tj|��|��dS)Nc��eZdZdS)�/TestCopy.test_deepcopy_issubclass.<locals>.MetaNr�rCrr�Metar' r�rr(c��eZdZdS)�,TestCopy.test_deepcopy_issubclass.<locals>.CNr�rCrrr-r*"r�rr-r�)rNrrr )rr(r-s   r�test_deepcopy_issubclassz!TestCopy.test_deepcopy_issubclasss���
	�	�	�	�	�4�	�	�	�	�	�	�	�	�$�	�	�	�	������q�)�)�1�-�-�-�-�-rc����G�fd�dt����d��}tj|��}|�|j|j��|�|j|j��dS)Nc�"��eZdZd�Zd�fd�	ZdS)�*TestCopy.test_deepcopy_deepcopy.<locals>.Cc��||_dSr
r&r(s  rr)z3TestCopy.test_deepcopy_deepcopy.<locals>.C.__init__(r*rNc�$���|j��Sr
r&�r�memor-s  �r�__deepcopy__z7TestCopy.test_deepcopy_deepcopy.<locals>.C.__deepcopy__*r/rr
)r0r1r2r)r3r3s�rr-r.'sB�������
�
�
�
#�
#�
#�
#�
#�
#�
#�
#rr-r)r4rr rr5r'r6s   @r�test_deepcopy_deepcopyzTestCopy.test_deepcopy_deepcopy&s����	#�	#�	#�	#�	#�	#�	#��	#�	#�	#�

�A�b�E�E���M�!���������a�k�2�2�2��������&�&�&�&�&rc���Gd�dt����fd�}�d��}|�ttj|��tj�|���tj|��}|�||��|�t|�����|�|j
|j
��dS)Nc��eZdZd�ZdS)�*TestCopy.test_deepcopy_registry.<locals>.Cc�H�t�|��}||_|Sr
r<r>s   rr=z2TestCopy.test_deepcopy_registry.<locals>.C.__new__3rArNrBrCrrr-r72rDrr-c����|jffSr
r&rFs �rrGz1TestCopy.test_deepcopy_registry.<locals>.pickle_C7rHrr)r4rIrJrr rKrLrMrrNr'rOs    @r�test_deepcopy_registryzTestCopy.test_deepcopy_registry1s����	�	�	�	�	��	�	�	�
	#�	#�	#�	#�	#�
�A�b�E�E�����)�T�]�A�6�6�6���q�(�A�&�&�&��M�!��������A��������a���!�$�$�$��������&�&�&�&�&rc����G�fd�dt��}g�|��}tj|��}|�||��|��dg��dS)Nc� ��eZdZ�fd�Zd�ZdS)�+TestCopy.test_deepcopy_reduce_ex.<locals>.Cc�2����d��dSrUrXrZs  �rr]z9TestCopy.test_deepcopy_reduce_ex.<locals>.C.__reduce_ex__Cr^rc�0�|�d��dSr`rars rrcz6TestCopy.test_deepcopy_reduce_ex.<locals>.C.__reduce__FrdrNrerfs�rr-r=Brgrr-rV�r4rr rrris    @r�test_deepcopy_reduce_exz TestCopy.test_deepcopy_reduce_exAs����	1�	1�	1�	1�	1�	1�	1��	1�	1�	1�
��
�A�C�C���M�!�����
�
�a���������Q�C� � � � � rc����G�fd�dt��}g�|��}tj|��}|�||��|��dg��dS)Nc���eZdZ�fd�ZdS)�(TestCopy.test_deepcopy_reduce.<locals>.Cc�2����d��dSrUrXros �rrcz3TestCopy.test_deepcopy_reduce.<locals>.C.__reduce__Pr^rNrprfs�rr-rDOrqrr-rVr@ris    @r�test_deepcopy_reducezTestCopy.test_deepcopy_reduceNs����	�	�	�	�	�	�	��	�	�	�
��
�A�C�C���M�!�����
�
�a���������Q�C� � � � � rc��Gd�dt��}|��}|�tjtj|��dS)Nc��eZdZd�ZdS)�&TestCopy.test_deepcopy_cant.<locals>.Cc��|�d��rt|���t�||��Srwryr}s  rr|z7TestCopy.test_deepcopy_cant.<locals>.C.__getattribute__[rrNr�rCrrr-rIZr�rr-)r4rIrrr r�s   r�test_deepcopy_cantzTestCopy.test_deepcopy_cantYs[��	;�	;�	;�	;�	;��	;�	;�	;�

�A�C�C�����$�*�d�m�Q�7�7�7�7�7rc��Gd�d��}d�}ddtdddzdd	d
ddd
d|j|td��tt	��g}|D]*}|�t
j|��|���+dS)Nc��eZdZdS)�/TestCopy.test_deepcopy_atomic.<locals>.NewStyleNr�rCrrr�rNer�rr�c��dSr
rCrCrrr�z(TestCopy.test_deepcopy_atomic.<locals>.fgr�r.rr�r�r�TFr�sbytesr�r�r�)r�r�r�r�r�rrr )rr�r�r�rs     r�test_deepcopy_atomiczTestCopy.test_deepcopy_atomicds���	�	�	�	�	�	�	�	�	�	�	��s�N�B��3���d�E�2��7�M�1�:��5��9�9�c�8�:�:�7���	/�	/�A��M�M�$�-��*�*�A�.�.�.�.�	/�	/rc���ddgdg}tj|��}|�||��|�||��|�|d|d��dS�NrVr�r�r�rr rrMrs   r�test_deepcopy_listzTestCopy.test_deepcopy_listo�n����V�Q�K���M�!��������A��������A��������1��q��t�$�$�$�$�$rc�T�g}|�|��tj|��}tD]}|�t
|||��� |�||��|�|d|��|�t|��d��dSr#)
rYrr �comparisonsrI�RecursionErrorrMrr�len�rrr �ops    r�test_deepcopy_reflexive_listz%TestCopy.test_deepcopy_reflexive_listvs�����	��������M�!�����	8�	8�B����n�b�!�Q�7�7�7�7�����A�����
�
�a��d�A��������Q����#�#�#�#�#rc�^�d}tj|��}|�||��dS�NrC�rr rrs   r�test_deepcopy_empty_tuplez"TestCopy.test_deepcopy_empty_tuple�s0�����M�!�����
�
�a������rc���ddgdf}tj|��}|�||��|�||��|�|d|d��dSrRrSrs   r�test_deepcopy_tuplezTestCopy.test_deepcopy_tuple�rUrc�^�d}tj|��}|�||��dS)N)�rVr�r�r_rs   r�!test_deepcopy_tuple_of_immutablesz*TestCopy.test_deepcopy_tuple_of_immutables�s0�����M�!�����
�
�a������rc�l�gf}|d�|��tj|��}tD]}|�t
|||��� |�||��|�|d|d��|�|dd|��dS�Nr)rYrr rWrIrXrMrrZs    r�test_deepcopy_reflexive_tuplez&TestCopy.test_deepcopy_reflexive_tuple�s���
�E��	�!����A�����M�!�����	8�	8�B����n�b�!�Q�7�7�7�7�����A��������1��q��t�$�$�$��
�
�a��d�1�g�q�!�!�!�!�!rc���ddgdd�}tj|��}|�||��|�||��|�|d|d��dS)NrVr�r�r�r'rSrs   r�test_deepcopy_dictzTestCopy.test_deepcopy_dict�sr����F�1�%�%���M�!��������A��������A��������5��1�U�8�,�,�,�,�,rc��i}||d<tj|��}tD]}|�t|||��� t
D]}|�t|||��� |�||��|�|d|��|�	t|��d��dS)Nr'rV)rr �order_comparisonsrIrJ�equality_comparisonsrXrMrrrYrZs    r�test_deepcopy_reflexive_dictz%TestCopy.test_deepcopy_reflexive_dict�s�������%���M�!����#�	3�	3�B����i��Q��2�2�2�2�&�	8�	8�B����n�b�!�Q�7�7�7�7�����A�����
�
�a��h��"�"�"�����Q����#�#�#�#�#rc��i}g}tj||��}|�|t|��d|��dSrg)rr r�id�rr2rr s    r�test_deepcopy_keepalivez TestCopy.test_deepcopy_keepalive�sF�������M�!�T�"�"���
�
�d�2�d�8�8�n�Q�'��+�+�+�+�+rc�T�i}gd�}tj||��}|�||��|�t|��d��i}dg}tj||��}|�||��|�t|��d��dS)N)rVr�r��r�rd)rr rrYrqs    r�!test_deepcopy_dont_memo_immutablez*TestCopy.test_deepcopy_dont_memo_immutable�s������L�L���M�!�T�"�"������A��������T���A�&�&�&���
�H���M�!�T�"�"������A��������T���A�&�&�&�&�&rc���Gd�d��}|dg��}tj|��}|�||��|�|j|j��dS)Nc��eZdZd�Zd�ZdS)�.TestCopy.test_deepcopy_inst_vanilla.<locals>.Cc��||_dSr
r&r(s  rr)z7TestCopy.test_deepcopy_inst_vanilla.<locals>.C.__init__�r*rc�"�|j|jkSr
r&r�s  rr�z5TestCopy.test_deepcopy_inst_vanilla.<locals>.C.__eq__�r�rNr�rCrrr-rx�r�rr-r�rr rrMr'r�s    r�test_deepcopy_inst_vanillaz#TestCopy.test_deepcopy_inst_vanilla�s���	-�	-�	-�	-�	-�	-�	-�	-�

�A�r�d�G�G���M�!��������A�����������&�&�&�&�&rc���G�fd�d����dg��}tj|��}|�||��|�||��|�|j|j��dS)Nc�&��eZdZd�Z�fd�Zd�ZdS)�/TestCopy.test_deepcopy_inst_deepcopy.<locals>.Cc��||_dSr
r&r(s  rr)z8TestCopy.test_deepcopy_inst_deepcopy.<locals>.C.__init__�r*rc�J���tj|j|����Sr
)rr r'r1s  �rr3z<TestCopy.test_deepcopy_inst_deepcopy.<locals>.C.__deepcopy__�s!����q���t�x��6�6�7�7�7rc�"�|j|jkSr
r&r�s  rr�z6TestCopy.test_deepcopy_inst_deepcopy.<locals>.C.__eq__�r�rN)r0r1r2r)r3r�r3s�rr-r�sL�������
�
�
�
8�
8�
8�
8�
8�
-�
-�
-�
-�
-rr-rr{r6s   @r�test_deepcopy_inst_deepcopyz$TestCopy.test_deepcopy_inst_deepcopy�s����	-�	-�	-�	-�	-�	-�	-�	-�	-�	-�
�A�r�d�G�G���M�!��������A��������A�����������&�&�&�&�&rc��Gd�d��}|dg��}tj|��}|�||��|�||��|�|j|j��dS)Nc� �eZdZd�Zd�Zd�ZdS)�2TestCopy.test_deepcopy_inst_getinitargs.<locals>.Cc��||_dSr
r&r(s  rr)z;TestCopy.test_deepcopy_inst_getinitargs.<locals>.C.__init__�r*rc��|jfSr
r&rs rr�zBTestCopy.test_deepcopy_inst_getinitargs.<locals>.C.__getinitargs__�r�rc�"�|j|jkSr
r&r�s  rr�z9TestCopy.test_deepcopy_inst_getinitargs.<locals>.C.__eq__�r�rNr�rCrrr-r��r�rr-rr{r�s    r�test_deepcopy_inst_getinitargsz'TestCopy.test_deepcopy_inst_getinitargs����	-�	-�	-�	-�	-�	-�	-�	-�
�A�r�d�G�G���M�!��������A��������A�����������&�&�&�&�&rc�p�Gd�dt��}|dg��}tj|��}|�||��|�||��|�||��|�|j|j��|�|j|j��dS)Nc� �eZdZd�Zd�Zd�ZdS)�1TestCopy.test_deepcopy_inst_getnewargs.<locals>.Cc�H�t�|��}||_|Sr
r�r�s   rr=z9TestCopy.test_deepcopy_inst_getnewargs.<locals>.C.__new__�r�rc��|jfSr
r&rs rr�z@TestCopy.test_deepcopy_inst_getnewargs.<locals>.C.__getnewargs__�r�rc�"�|j|jkSr
r&r�s  rr�z8TestCopy.test_deepcopy_inst_getnewargs.<locals>.C.__eq__�r�rNr�rCrrr-r��r�rr-r�r�rr r�rrMr'r�s    r�test_deepcopy_inst_getnewargsz&TestCopy.test_deepcopy_inst_getnewargs�s���	-�	-�	-�	-�	-��	-�	-�	-�
�A�r�d�G�G���M�!�������a��#�#�#�����A��������A�����������&�&�&��������&�&�&�&�&rc�r�Gd�dt��}|dg���}tj|��}|�||��|�||��|�||��|�|j|j��|�|j|j��dS)Nc� �eZdZd�Zd�Zd�ZdS)�4TestCopy.test_deepcopy_inst_getnewargs_ex.<locals>.Cc�H�t�|��}||_|Sr
r�r�s   rr=z<TestCopy.test_deepcopy_inst_getnewargs_ex.<locals>.C.__new__�r�rc��dd|jifSr�r&rs rr�zFTestCopy.test_deepcopy_inst_getnewargs_ex.<locals>.C.__getnewargs_ex__r�rc�"�|j|jkSr
r&r�s  rr�z;TestCopy.test_deepcopy_inst_getnewargs_ex.<locals>.C.__eq__r�rNr�rCrrr-r��r�rr-rr&r�r�s    r� test_deepcopy_inst_getnewargs_exz)TestCopy.test_deepcopy_inst_getnewargs_ex�s���	-�	-�	-�	-�	-��	-�	-�	-�
�A�2�$�K�K�K���M�!�������a��#�#�#�����A��������A�����������&�&�&��������&�&�&�&�&rc��Gd�d��}|dg��}tj|��}|�||��|�||��|�|j|j��dS)Nc� �eZdZd�Zd�Zd�ZdS)�/TestCopy.test_deepcopy_inst_getstate.<locals>.Cc��||_dSr
r&r(s  rr)z8TestCopy.test_deepcopy_inst_getstate.<locals>.C.__init__r*rc��d|jiSr�r&rs rrz<TestCopy.test_deepcopy_inst_getstate.<locals>.C.__getstate__rrc�"�|j|jkSr
r&r�s  rr�z6TestCopy.test_deepcopy_inst_getstate.<locals>.C.__eq__r�rNrrCrrr-r�rrr-rr{r�s    r�test_deepcopy_inst_getstatez$TestCopy.test_deepcopy_inst_getstater�rc��Gd�d��}|dg��}tj|��}|�||��|�||��|�|j|j��dS)Nc� �eZdZd�Zd�Zd�ZdS)�/TestCopy.test_deepcopy_inst_setstate.<locals>.Cc��||_dSr
r&r(s  rr)z8TestCopy.test_deepcopy_inst_setstate.<locals>.C.__init__r*rc� �|d|_dSr�r&rs  rr
z<TestCopy.test_deepcopy_inst_setstate.<locals>.C.__setstate__ rrc�"�|j|jkSr
r&r�s  rr�z6TestCopy.test_deepcopy_inst_setstate.<locals>.C.__eq__"r�rNrrCrrr-r�rrr-rr{r�s    r�test_deepcopy_inst_setstatez$TestCopy.test_deepcopy_inst_setstater�rc���Gd�d��}|dg��}tj|��}|�||��|�||��|�|j|j��|g��}tj|��}|�||��|�||��|�|j|j��dS)Nc�&�eZdZd�Zd�Zd�Zd�ZdS)�8TestCopy.test_deepcopy_inst_getstate_setstate.<locals>.Cc��||_dSr
r&r(s  rr)zATestCopy.test_deepcopy_inst_getstate_setstate.<locals>.C.__init__,r*rc��|jSr
r&rs rrzETestCopy.test_deepcopy_inst_getstate_setstate.<locals>.C.__getstate__.rrc��||_dSr
r&rs  rr
zETestCopy.test_deepcopy_inst_getstate_setstate.<locals>.C.__setstate__0rrc�"�|j|jkSr
r&r�s  rr�z?TestCopy.test_deepcopy_inst_getstate_setstate.<locals>.C.__eq__2r�rNrrCrrr-r�+rrr-rr{r�s    r�$test_deepcopy_inst_getstate_setstatez-TestCopy.test_deepcopy_inst_getstate_setstate*s���	-�	-�	-�	-�	-�	-�	-�	-�
�A�r�d�G�G���M�!��������A��������A�����������&�&�&�
�A�b�E�E���M�!��������A��������A�����������&�&�&�&�&rc���Gd�d��}|��}||_tj|��}|�||��|�|j|��dS)Nc��eZdZdS)�0TestCopy.test_deepcopy_reflexive_inst.<locals>.CNr�rCrrr-r�Ar�rr-)r'rr rMrr�s    r�test_deepcopy_reflexive_instz%TestCopy.test_deepcopy_reflexive_inst@s}��	�	�	�	�	�	�	�	�
�A�C�C������M�!��������A�����
�
�a�e�Q�����rc���Gd�dt��}|��}tj|��}|�||��tj|��}|�||��dS)Nc��eZdZd�ZdS)�+TestCopy.test_reconstruct_string.<locals>.Cc��dS)NrWrCrs rrcz6TestCopy.test_reconstruct_string.<locals>.C.__reduce__Ms���rrNrprCrrr-r�Ls#������
�
�
�
�
rr-)r4rrr r�s    r�test_reconstruct_stringz TestCopy.test_reconstruct_stringKs���	�	�	�	�	��	�	�	�
�A�C�C���I�a�L�L���
�
�a������M�!�����
�
�a������rc�$��G�fd�dt������}d|_tj|��}|�|j|j��tj|��}|�|j|j��dS)Nc���eZdZ�fd�ZdS)�,TestCopy.test_reconstruct_nostate.<locals>.Cc����dfSr^rCr,s �rrcz7TestCopy.test_reconstruct_nostate.<locals>.C.__reduce__Ws����2�w�rNrpr3s�rr-r�Vs.�������
�
�
�
�
�
�
rr-r)r4r'rrr5r r6s   @r�test_reconstruct_nostatez!TestCopy.test_reconstruct_nostateUs����	�	�	�	�	�	�	��	�	�	�
�A�C�C������I�a�L�L���
�
�a�k�1�;�/�/�/��M�!�����
�
�a�k�1�;�/�/�/�/�/rc�>��G�fd�dt������}dg|_tj|��}|�||��tj|��}|�||��|�|j|j��dS)Nc� ��eZdZ�fd�Zd�ZdS)�*TestCopy.test_reconstruct_state.<locals>.Cc����d|jfSr^��__dict__r,s �rrcz5TestCopy.test_reconstruct_state.<locals>.C.__reduce__b�����2�t�}�-�-rc�"�|j|jkSr
r�r�s  rr�z1TestCopy.test_reconstruct_state.<locals>.C.__eq__d����}���6�6rN�r0r1r2rcr�r3s�rr-r�as=�������
.�
.�
.�
.�
.�
7�
7�
7�
7�
7rr-r�r4r'rrr rMr6s   @r�test_reconstruct_statezTestCopy.test_reconstruct_state`s����	7�	7�	7�	7�	7�	7�	7��	7�	7�	7�

�A�C�C�������I�a�L�L������A�����M�!��������A�����������&�&�&�&�&rc�>��G�fd�dt������}dg|_tj|��}|�||��tj|��}|�||��|�|j|j��dS)Nc�&��eZdZ�fd�Zd�Zd�ZdS)�3TestCopy.test_reconstruct_state_setstate.<locals>.Cc����d|jfSr^r�r,s �rrcz>TestCopy.test_reconstruct_state_setstate.<locals>.C.__reduce__pr�rc�:�|j�|��dSr
)r��updaters  rr
z@TestCopy.test_reconstruct_state_setstate.<locals>.C.__setstate__rs���
�$�$�U�+�+�+�+�+rc�"�|j|jkSr
r�r�s  rr�z:TestCopy.test_reconstruct_state_setstate.<locals>.C.__eq__tr�rN)r0r1r2rcr
r�r3s�rr-r�osL�������
.�
.�
.�
.�
.�
,�
,�
,�
7�
7�
7�
7�
7rr-rr�r6s   @r�test_reconstruct_state_setstatez(TestCopy.test_reconstruct_state_setstatens����	7�	7�	7�	7�	7�	7�	7��	7�	7�	7�
�A�C�C�������I�a�L�L������A�����M�!��������A�����������&�&�&�&�&rc���Gd�dt��}|��}||_tj|��}|�||��|�|j|��dS)Nc��eZdZdS)�.TestCopy.test_reconstruct_reflexive.<locals>.CNr�rCrrr-r�r�rr-)r4r'rr rMrr�s    r�test_reconstruct_reflexivez#TestCopy.test_reconstruct_reflexive~s��	�	�	�	�	��	�	�	�
�A�C�C������M�!��������A�����
�
�a�e�Q�����rc����G�fd�dt����ddgdg��}tj|��}|�||��|�||��|�|d|d��tj|��}|�||��|�||��|�|d|d��dS)Nc� ��eZdZ�fd�Zd�ZdS)�&TestCopy.test_reduce_4tuple.<locals>.Cc�4���d|jt|��fSr^)r��iterr,s �rrcz1TestCopy.test_reduce_4tuple.<locals>.C.__reduce__�s����2�t�}�d�4�j�j�9�9rc�b�t|��t|��ko|j|jkSr
)�listr�r�s  rr�z-TestCopy.test_reduce_4tuple.<locals>.C.__eq__��,���T�
�
�d�5�k�k�1�8��
���7�9rNr�r3s�rr-r��s=�������
:�
:�
:�
:�
:�
9�
9�
9�
9�
9rr-rVr�r�r)r�rrrMrr r6s   @r�test_reduce_4tuplezTestCopy.test_reduce_4tuple�s���	9�	9�	9�	9�	9�	9�	9��	9�	9�	9�
�A��1�v�q�k�N�N���I�a�L�L������A��������A�����
�
�a��d�A�a�D�!�!�!��M�!��������A��������A��������1��q��t�$�$�$�$�$rc����G�fd�dt����dddgfdg��}tj|��}|�||��|�||��|�|d|d��tj|��}|�||��|�||��|�|d|d��dS)Nc� ��eZdZ�fd�Zd�ZdS)�&TestCopy.test_reduce_5tuple.<locals>.Cc�@���d|jd|���fSr^)r��itemsr,s �rrcz1TestCopy.test_reduce_5tuple.<locals>.C.__reduce__�s����2�t�}�d�D�J�J�L�L�A�Arc�b�t|��t|��ko|j|jkSr
)�dictr�r�s  rr�z-TestCopy.test_reduce_5tuple.<locals>.C.__eq__�r�rNr�r3s�rr-r��sB�������
B�
B�
B�
B�
B�
9�
9�
9�
9�
9rr-r'rVr�)r�r�)r�rrrMrr r6s   @r�test_reduce_5tuplezTestCopy.test_reduce_5tuple�s	���	9�	9�	9�	9�	9�	9�	9��	9�	9�	9�
�A���1�v��
�+�,�,���I�a�L�L������A��������A�����
�
�a��h��%��)�)�)��M�!��������A��������A��������5��1�U�8�,�,�,�,�,rc�d�����fd��G��fd�d������}��t��5tj|��ddd��n#1swxYwY��t��5tj|��ddd��dS#1swxYwYdS)Nc�2����d��dSr`ra)�args�kwargsrs  �r�state_setterz1TestCopy.test_reduce_6tuple.<locals>.state_setter�s����I�I�+�,�,�,�,�,rc���eZdZ��fd�ZdS)�&TestCopy.test_reduce_6tuple.<locals>.Cc����d|jdd�fSr^r�)rr-r�s ��rrcz1TestCopy.test_reduce_6tuple.<locals>.C.__reduce__�s����"�d�m�T�4��E�ErNrp)r-r�s��rr-r��s;�������
F�
F�
F�
F�
F�
F�
F�
Frr-�rIrJrr )rrr-r�s` @@r�test_reduce_6tuplezTestCopy.test_reduce_6tuple�sk�����	-�	-�	-�	-�	-�	F�	F�	F�	F�	F�	F�	F�	F�	F�	F�	F�
�A�C�C��
�
�
�y�
)�
)�	�	��I�a�L�L�L�	�	�	�	�	�	�	�	�	�	�	����	�	�	�	�
�
�
�y�
)�
)�	�	��M�!����	�	�	�	�	�	�	�	�	�	�	�	����	�	�	�	�	�	s#�A�A"�%A"�B%�%B)�,B)c�T��G�fd�d������}|�t��5tj|��ddd��n#1swxYwY|�t��5tj|��ddd��dS#1swxYwYdS)Nc���eZdZ�fd�ZdS)�+TestCopy.test_reduce_6tuple_none.<locals>.Cc����d|jdddfSr^r�r,s �rrcz6TestCopy.test_reduce_6tuple_none.<locals>.C.__reduce__�s����"�d�m�T�4��=�=rNrpr3s�rr-r��s.�������
>�
>�
>�
>�
>�
>�
>rr-r�r�s  @r�test_reduce_6tuple_nonez TestCopy.test_reduce_6tuple_none�s@���	>�	>�	>�	>�	>�	>�	>�	>�	>�	>�
�A�C�C��
�
�
�y�
)�
)�	�	��I�a�L�L�L�	�	�	�	�	�	�	�	�	�	�	����	�	�	�	�
�
�
�y�
)�
)�	�	��M�!����	�	�	�	�	�	�	�	�	�	�	�	����	�	�	�	�	�	s#�A�A�A�;B�B!�$B!c��Gd�dt��}|��}dg|_tj|��}|�|j|j��dS)Nc��eZdZdgZdS)�#TestCopy.test_copy_slots.<locals>.Cr'N�r0r1r2�	__slots__rCrrr-r�����������I�I�Irr-r)r4r'rrr�s    r�test_copy_slotszTestCopy.test_copy_slots�sk��	 �	 �	 �	 �	 ��	 �	 �	 �
�A�C�C�������I�a�L�L���
�
�a�e�Q�U�#�#�#�#�#rc��Gd�dt��}|��}dg|_tj|��}|�|j|j��|�|j|j��dS)Nc��eZdZdgZdS)�'TestCopy.test_deepcopy_slots.<locals>.Cr'Nr�rCrrr-r�r�rr-r)r4r'rr rrMr�s    r�test_deepcopy_slotszTestCopy.test_deepcopy_slots�s���	 �	 �	 �	 �	 ��	 �	 �	 �
�A�C�C�������M�!�����������&�&�&��������&�&�&�&�&rc�~�Gd�dt��}|ddi���}tj|��}|�||��|�|j|j��|�||��d|d<|�||��|�|j|j��dS)Nc�*��eZdZd�fd�	Z�fd�Z�xZS)�/TestCopy.test_deepcopy_dict_subclass.<locals>.CNc���|si}t|�����|_t���|��dSr
)r��keys�_keys�superr))r�dr5s  �rr)z8TestCopy.test_deepcopy_dict_subclass.<locals>.C.__init__�sC������A�!�!�&�&�(�(�^�^��
���� � ��#�#�#�#�#rc���t���||��||jvr|j�|��dSdSr
)r�__setitem__rrY)r�key�itemr5s   �rrz;TestCopy.test_deepcopy_dict_subclass.<locals>.C.__setitem__�sN������#�#�C��.�.�.��d�j�(�(��J�%�%�c�*�*�*�*�*�)�(rr
)r0r1r2r)r�
__classcell__)r5s@rr-r�sV�������
$�
$�
$�
$�
$�
$�

+�
+�
+�
+�
+�
+�
+�
+�
+rr-r'r)r	rVr�)r�rr rrrM�assertNotEqualr�s    r�test_deepcopy_dict_subclassz$TestCopy.test_deepcopy_dict_subclass�s���		+�		+�		+�		+�		+��		+�		+�		+�
�A��q�	�N�N�N���M�!��������A���������!�'�*�*�*�����A������%�����A�q�!�!�!����A�G�Q�W�-�-�-�-�-rc��Gd�dt��}|ddgdg��}ddg|_tj|��}|�t|��t|����|�|j|j��|�|d|d��|�|j|j��dS)	Nc��eZdZdS)�+TestCopy.test_copy_list_subclass.<locals>.CNr�rCrrr-r�r�rr-rVr�r�rt�r)r�r'rrrr�s    r�test_copy_list_subclassz TestCopy.test_copy_list_subclass�s���	�	�	�	�	��	�	�	�
�A��1�v�q�k�N�N���A�����I�a�L�L������a���$�q�'�'�*�*�*��������&�&�&��
�
�a��d�A�a�D�!�!�!��
�
�a�e�Q�U�#�#�#�#�#rc��Gd�dt��}|ddgdg��}ddg|_tj|��}|�t|��t|����|�|j|j��|�|d|d��|�|j|j��dS)	Nc��eZdZdS)�/TestCopy.test_deepcopy_list_subclass.<locals>.CNr�rCrrr-r�r�rr-rVr�r�rtrr)r�r'rr rrMr�s    r�test_deepcopy_list_subclassz$TestCopy.test_deepcopy_list_subclass�s���	�	�	�	�	��	�	�	�
�A��1�v�q�k�N�N���A�����M�!��������a���$�q�'�'�*�*�*��������&�&�&�����1��q��t�$�$�$��������&�&�&�&�&rc��Gd�dt��}|gd���}|�t|��d��tj|��}|�t|��d��dS)Nc��eZdZdS)�,TestCopy.test_copy_tuple_subclass.<locals>.CNr�rCrrr-r�r�rr-r�)�tuplerrr�s    r�test_copy_tuple_subclassz!TestCopy.test_copy_tuple_subclass�s���	�	�	�	�	��	�	�	�
�A�i�i�i�L�L������q���9�-�-�-��I�a�L�L������q���9�-�-�-�-�-rc�~�Gd�dt��}|ddgdg��}|�t|��ddgdf��tj|��}|�t|��ddgdf��|�||��|�|d|d��dS)Nc��eZdZdS)�0TestCopy.test_deepcopy_tuple_subclass.<locals>.CNr�rCrrr-r!r�rr-rVr�r�r)rrrr rMr�s    r�test_deepcopy_tuple_subclassz%TestCopy.test_deepcopy_tuple_subclasss���	�	�	�	�	��	�	�	�
�A��1�v�q�k�N�N������q���Q��F�A�;�/�/�/��M�!��������q���Q��F�A�;�/�/�/�����A��������1��q��t�$�$�$�$�$rc��Gd�dt��}|�ttj|����dS)Nc��eZdZd�ZdS)�-TestCopy.test_getstate_exc.<locals>.EvilStatec� �td���)Nzain't got no stickin' state)�
ValueErrorrs rrz:TestCopy.test_getstate_exc.<locals>.EvilState.__getstate__s�� �!>�?�?�?rN)r0r1r2rrCrr�	EvilStater%s(������
@�
@�
@�
@�
@rr()r4rIr'r)rr(s  r�test_getstate_exczTestCopy.test_getstate_excs\��	@�	@�	@�	@�	@��	@�	@�	@�	
���*�d�i�����=�=�=�=�=rc��|�tjt��t��d�}|�tj|��|��d�}|�tj|��|��dS)Nc��||zSr
rC�rr s  rr'z(TestCopy.test_copy_function.<locals>.foo�
��a��c�zrc��dSr
rCrCrr�<lambda>z-TestCopy.test_copy_function.<locals>.<lambda>���d�r)rr�
global_foo�rr'r�s   r�test_copy_functionzTestCopy.test_copy_functionst�������:�.�.�
�;�;�;�!�!�!������3����-�-�-��l�������3����-�-�-�-�-rc��|�tjt��t��d�}|�tj|��|��d�}|�tj|��|��dS)Nc��||zSr
rCr,s  rr'z,TestCopy.test_deepcopy_function.<locals>.foor-rc��dSr
rCrCrrr/z1TestCopy.test_deepcopy_function.<locals>.<lambda>r0r)rrr r1r2s   r�test_deepcopy_functionzTestCopy.test_deepcopy_functionsx�������z�2�2�J�?�?�?�!�!�!������s�+�+�S�1�1�1��l�������s�+�+�S�1�1�1�1�1rc���Gd�dt��}|��}tj|��}||��}|�||��~||��}|�||��dS)Nc��eZdZdS)�"TestCopy._check_weakref.<locals>.CNr�rCrrr-r:#r�rr-)r4�weakref�refr)r�_copyr-r@rr s      r�_check_weakrefzTestCopy._check_weakref"s���	�	�	�	�	��	�	�	��a�c�c���K������E�!�H�H���
�
�a�������E�!�H�H���
�
�a������rc�D�|�tj��dSr
)r>rrs r�test_copy_weakrefzTestCopy.test_copy_weakref-s�����D�I�&�&�&�&�&rc�D�|�tj��dSr
)r>rr rs r�test_deepcopy_weakrefzTestCopy.test_deepcopy_weakref0s�����D�M�*�*�*�*�*rc��
�Gd�dt���
�
fd�td��D��\}}}}|��}|||<|||<tj|��}|�||��|�||��|�|||��|�|||��|�t|��d��~~t
j��|�t|��d���
���
��}	}|	||<|�||��dS)Nc��eZdZdS)�(TestCopy._check_copy_weakdict.<locals>.CNr�rCrrr-rE4r�rr-c�$��g|]}�����
SrCrC��.0�ir-s  �r�
<listcomp>z1TestCopy._check_copy_weakdict.<locals>.<listcomp>6s���,�,�,�a�a�a�c�c�,�,�,rrtr�rV)	r4r�rrMrrYr	�
gc_collect�assertNotIn)r�	_dicttype�a�br\r	�u�vrr r-s          @r�_check_copy_weakdictzTestCopy._check_copy_weakdict3sd���	�	�	�	�	��	�	�	�,�,�,�,�5��8�8�,�,�,�
��1�a���I�K�K����!����!���I�a�L�L������A��������A��������1��q�!�!�!�����1��q�!�!�!�����Q����#�#�#�
�q����������Q����#�#�#��q�s�s�A�A�C�C�1����!������A�����rc�D�|�tj��dSr
)rRr;�WeakKeyDictionaryrs r�test_copy_weakkeydictzTestCopy.test_copy_weakkeydictHs���!�!�'�";�<�<�<�<�<rc�D�|�tj��dSr
)rRr;�WeakValueDictionaryrs r�test_copy_weakvaluedictz TestCopy.test_copy_weakvaluedictKs���!�!�'�"=�>�>�>�>�>rc���Gd�dt����fd�td��D��\}}}}tj��}|||<|||<t	j|��}|�||��|�t|��d��|�	|||��|�	|||��|�||j
|j
��|�||j
|j
��~tj��|�t|��d��dS)Nc��eZdZd�ZdS)�-TestCopy.test_deepcopy_weakkeydict.<locals>.Cc��||_dSr
�rI�rrIs  rr)z6TestCopy.test_deepcopy_weakkeydict.<locals>.C.__init__P�
������rN�r0r1r2r)rCrrr-r[O�#������
�
�
�
�
rr-c�&��g|]
}�|����SrCrCrGs  �rrJz6TestCopy.test_deepcopy_weakkeydict.<locals>.<listcomp>R�!���-�-�-�q�a�a��d�d�-�-�-rrtr�rV)
r4r�r;rTrr rrrYrMrIr	rK)rrNrOr\r	rPrQr-s       @r�test_deepcopy_weakkeydictz"TestCopy.test_deepcopy_weakkeydictNs[���	�	�	�	�	��	�	�	�.�-�-�-�E�!�H�H�-�-�-�
��1�a���%�'�'����!����!���M�!�������A�q�!�!�!�����Q����#�#�#�����1��q�!�!�!�����1��q�!�!�!�����1�����%�%�%�����1�����%�%�%�
����������Q����#�#�#�#�#rc�B��Gd�dt����fd�td��D��\}}}}tj��}|||<|||<t	j|��}|�||��|�t|��d��t|�
��d����\\}}\}	}
|�||��|�|j|j��|�
||��|�|	|��|�|	j|j��|�
|
|��~~~	~
~tj��|�t|��d��dS)	Nc��eZdZd�ZdS)�/TestCopy.test_deepcopy_weakvaluedict.<locals>.Cc��||_dSr
r]r^s  rr)z8TestCopy.test_deepcopy_weakvaluedict.<locals>.C.__init__dr_rNr`rCrrr-rgcrarr-c�&��g|]
}�|����SrCrCrGs  �rrJz8TestCopy.test_deepcopy_weakvaluedict.<locals>.<listcomp>frcrrtr�c��|djSrgr])�pairs rr/z6TestCopy.test_deepcopy_weakvaluedict.<locals>.<lambda>ns��D��G�I�r)rrV)r4r�r;rWrr rrrY�sortedr�rMrIrr	rK)rrNrOr\r	rPrQrr �z�tr-s           @r�test_deepcopy_weakvaluedictz$TestCopy.test_deepcopy_weakvaluedictbs����	�	�	�	�	��	�	�	�.�-�-�-�E�!�H�H�-�-�-�
��1�a���'�)�)����!����!���M�!�������A�q�!�!�!�����Q����#�#�#�����	�	�/E�/E�F�F�F����A���A�����A���������a�c�"�"�"��
�
�a���������A���������a�c�"�"�"��
�
�a�����
�q�!�Q�
����������Q����#�#�#�#�#rc�(�Gd�dt��}|��}|j|_tj|��}|�|j|j��|�|jj|��|���dS)Nc��eZdZd�ZdS)�0TestCopy.test_deepcopy_bound_method.<locals>.Fooc��dSr
rCrs r�mz2TestCopy.test_deepcopy_bound_method.<locals>.Foo.m|s���rN)r0r1r2rtrCrr�Foorr{s#������
�
�
�
�
rru)r4rtrOrr rr�__self__)rrur��gs    r�test_deepcopy_bound_methodz#TestCopy.test_deepcopy_bound_methodzs���	�	�	�	�	�&�	�	�	�
�C�E�E���c����M�!���������a�c�"�"�"��
�
�a�c�l�A�&�&�&�	�������rN)Qr0r1r2rr!r7rPrjrrr�r�r�r�r�r�r�r�r�r�r�r�r�rrrr!r$r+r4r:rArFrKrPrTr\r`rbrerhrjrnrrrur|r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�rrrrrr"r)r3r7r>r@rBrRrUrXrdrorxrCrrrrs�������;�;�;����
	'�	'�	'�'�'�'� !�!�!�	!�	!�	!�4�4�4�
+�
+�
+����'�'�'�������'�'�'����*�*�*�	*�	*�	*�	*�	*�	*�'�'�'�"'�'�'�"	*�	*�	*�	*�	*�	*�*�*�*�$���
	"�	"�	"�	.�	.�	.�	'�	'�	'�'�'�'� !�!�!�	!�	!�	!�8�8�8�	/�	/�	/�%�%�%�$�$�$����
%�%�%����
"�"�"�-�-�-�
$�
$�
$�,�,�,�
'�
'�
'�	'�	'�	'�'�'�'�'�'�'�'�'�'�$'�'�'�$'�'�'�'�'�'�'�'�'�, � � ����	0�	0�	0�'�'�'�'�'�'�  � � �%�%�%�"-�-�-�"
�
�
����$�$�$�'�'�'�.�.�.�(	$�	$�	$�	'�	'�	'�.�.�.�%�%�%�>�>�>�.�.�.�2�2�2�	�	�	�'�'�'�+�+�+����*=�=�=�?�?�?�$�$�$�($�$�$�0	�	�	�	�	rrc��||zSr
rCr,s  rr1r1�s
��Q�q�S�jr�__main__)rrKr;r��operatorrrrrrr�unittest�testr	rlrmrW�TestCaserr1r0�mainrCrr�<module>r�s���%�������������
�
�
�
�+�+�+�+�+�+�+�+�+�+�+�+�+�+�+�+�������������B��N���2�v���"6�6��s
�s
�s
�s
�s
�x� �s
�s
�s
�l!� � ��z����H�M�O�O�O�O�O��r

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists