HEX
Server: Microsoft-IIS/10.0
System: Windows NT ITPWINWEBSVR22 10.0 build 20348 (Windows Server 2022) AMD64
User: www.conferencesearch.co.uk (0)
PHP: 8.3.30
Disabled: NONE
Upload Files
File: D:/Python311/Lib/test/test_importlib/__pycache__/test_spec.cpython-311.pyc
�

��Vc�~��B�ddlmZejd��Zejd��Zejd��ZddlZddlZddl	m
Z
ddlZddlZddl
Z
Gd�d��ZGd	�d
e��ZGd�de��ZGd
�d��Zejeee���\ZZGd�d��Zejeeee���\ZZGd�d��Zejeeee���\ZZGd�d��Zejeee���\ZZedkrej��dSdS)�)�util�	importlibzimportlib.machineryzimportlib.utilN)�CleanImportc�4�eZdZdd�Zd�Zd�Zd�Zd�Zd�ZdS)	�
TestLoaderNc�"�||_||_dS�N)�path�package)�selfr
�
is_packages   �1D:\Python311\Lib\test\test_importlib\test_spec.py�__init__zTestLoader.__init__s����	�!�����c��dS)Nz<TestLoader object>��rs r�__repr__zTestLoader.__repr__s��$�$rc�b�|dkr|j�|jS|dkr|jSt|���)N�get_filenamer
)r
�
_get_filename�_is_package�AttributeError�r�names  r�__getattr__zTestLoader.__getattr__sE���>�!�	&�d�i�	&��%�%��<��	$��#�#��T�"�"�"rc��|jSr	)r
rs  rrzTestLoader._get_filename s
���y�rc��|jSr	)rrs  rrzTestLoader._is_package#s
���|�rc��dSr	r�r�specs  r�
create_modulezTestLoader.create_module&s���tr)NN)	�__name__�
__module__�__qualname__rrrrrr"rrrrrss������"�"�"�"�%�%�%�#�#�#�����������rrc��eZdZdZd�ZdS)�	NewLoader�c��|j|_dSr	)�EGGS�eggs�r�modules  r�exec_modulezNewLoader.exec_module.s���i����rN)r#r$r%r*r.rrrr'r'*s(�������D� � � � � rr'c��eZdZdZej��5ejde��edZ	e	j
d���Zddd��dS#1swxYwYdS)�LegacyLoader����ignore�Frozenc��|j|_|Sr	)�HAM�hamr,s  r�load_modulezLegacyLoader.load_module;s����F�J��MrN)r#r$r%r5�warnings�catch_warnings�simplefilter�DeprecationWarningr�frozen_util�module_for_loaderr7rrrr0r02s�������
�C�	 ��	 �	"�	"������h�(:�;�;�;��8�n��	�	&�	�	�
'�	&�	�
��������������������s�*A
�
A�Ar0c��eZdZd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�Zd�Z
d�Zd
�Zd�Zd�Zd�Zd�Zd�Zd�ZdS)�ModuleSpecTestsc�^�d|_d|_|j�|j��|_t��|_|j�|j|j��|_	|j�|j|j|j���|_
d|j
_dS�N�spam�spam.py��originT�rr
r�cache_from_source�cachedr�loader�	machinery�
ModuleSpecr!�loc_spec�
_set_fileattrrs r�setUpzModuleSpecTests.setUpC�����	���	��i�1�1�$�)�<�<��� �l�l����N�-�-�d�i���E�E��	���1�1�$�)�T�[�9=��2�D�D��
�&*��
�#�#�#rc���|j�|j|j��}|�|j|j��|�|j|j��|�|jd��|�|jd��|�|jd��|�|j	d��|�
|j��dSr	�rJrKrrI�assertEqual�assertIsrE�loader_state�submodule_search_locationsrH�assertFalse�has_locationr s  r�test_defaultzModuleSpecTests.test_defaultMs����~�(�(���D�K�@�@�������D�I�.�.�.������d�k�2�2�2��
�
�d�k�4�(�(�(��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���|j�|jd��}|�|j|j��|�|jd��|�|jd��|�|jd��|�|jd��|�|j	d��|�
|j��dSr	)rJrKrrRrSrIrErTrUrHrVrWr s  r�test_default_no_loaderz&ModuleSpecTests.test_default_no_loaderXs����~�(�(���D�9�9�������D�I�.�.�.��
�
�d�k�4�(�(�(��
�
�d�k�4�(�(�(��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���|j�|j|jd���}|�|j|j��|�|j|j��|�|jd��|�|jd��|�|jd��|�|j	d��|�
|j��dS�NF�r
rQr s  r�test_default_is_package_falsez-ModuleSpecTests.test_default_is_package_falsecs����~�(�(���D�K�49�)�;�;��	
�����D�I�.�.�.������d�k�2�2�2��
�
�d�k�4�(�(�(��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���|j�|j|jd���}|�|j|j��|�|j|j��|�|jd��|�|jd��|�|jg��|�|j	d��|�
|j��dS�NTr]rQr s  r�test_default_is_package_truez,ModuleSpecTests.test_default_is_package_trueos����~�(�(���D�K�48�)�:�:��	
�����D�I�.�.�.������d�k�2�2�2��
�
�d�k�4�(�(�(��
�
�d�'��.�.�.�����8�"�=�=�=��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���|j�|j|jd���}|�|j��d|_|�|j��dS)N�	somewhererDT)rJrKrrIrVrW�
assertTruer s  r�test_has_location_setterz(ModuleSpecTests.test_has_location_setter{sc���~�(�(���D�K�0;�)�=�=������*�+�+�+� �������)�*�*�*�*�*rc��ttj��|j|jdddd���}|�|j|k��dS)NF�rrIrErUrWrH)�type�sys�implementationrrIrdr!�r�others  r�
test_equalityzModuleSpecTests.test_equality�sY��(��S�'�(�(�d�i�04��04�DH�6;�04�+�+�+��	
����	�U�*�+�+�+�+�+rc��ttj��|j|j|jdd|j���}|�|j|��dS)NTrg)	rhrirjrrIr
rHrRrLrks  r�test_equality_locationz&ModuleSpecTests.test_equality_location�s\��(��S�'�(�(�d�i�04��04�	�DH�6:�04��+�+�+��	
������.�.�.�.�.rc��ttj��d|jdddd���}|�|j|��dS)Nr6Frg)rhrirjrI�assertNotEqualr!rks  r�test_inequalityzModuleSpecTests.test_inequality�sV��(��S�'�(�(�e�04��04�DH�6;�04�+�+�+��	
���D�I�u�-�-�-�-�-rc��ttj��|j|j���}|�|j|��dS)N)rrI)rhrirjrrIrqr!rks  r�test_inequality_incompletez*ModuleSpecTests.test_inequality_incomplete�sL��(��S�'�(�(�d�i�04��+�+�+��	
���D�I�u�-�-�-�-�-rc�|�|j�d|j��}|�|jd��dS)N�	spam.eggsrB�rJrKrIrR�parentr s  r�test_packagezModuleSpecTests.test_package�s9���~�(�(��d�k�B�B�������f�-�-�-�-�-rc��|j�d|jd���}|�|jd��dS)NrvTr]rwr s  r�test_package_is_packagez'ModuleSpecTests.test_package_is_package�sG���~�(�(��d�k�48�)�:�:��	
�����k�2�2�2�2�2rc��|jj}d|j_|jj}|�|d��|�|d��dS)N�there)r!rHrSrR)r�before�afters   r�test_cached_setzModuleSpecTests.test_cached_set�sP����!��"��	���	� ���
�
�f�d�#�#�#������(�(�(�(�(rc��|j�|j|j��}|�|jd��dSr	)rJrKrrIrSrHr s  r�test_cached_no_originz%ModuleSpecTests.test_cached_no_origin�s9���~�(�(���D�K�@�@���
�
�d�k�4�(�(�(�(�(rc��|j�|j|j|j���}|�|jd��dS)NrD)rJrKrrIr
rSrHr s  r�$test_cached_with_origin_not_locationz4ModuleSpecTests.test_cached_with_origin_not_location�sI���~�(�(���D�K�04�	�)�;�;��	
�
�
�d�k�4�(�(�(�(�(rc��|j�|j��}|�|jj|��dSr	)rrGr
rRrLrH)r�expecteds  r�test_cached_sourcez"ModuleSpecTests.test_cached_source�s:���9�.�.�t�y�9�9�������-�x�8�8�8�8�8rc�^�d|j_|�|jjd��dS)Nzspam.spamspamspam)rLrErSrHrs r�!test_cached_source_unknown_suffixz1ModuleSpecTests.test_cached_source_unknown_suffix�s+��2��
���
�
�d�m�*�D�1�1�1�1�1rc���tjj}dtj_	|jj}|tj_n#|tj_wxYw|�|d��dSr	)rirj�	cache_tagrLrHrS)r�originalrHs   r�$test_cached_source_missing_cache_tagz4ModuleSpecTests.test_cached_source_missing_cache_tag�sf���%�/��'+���$�	4��]�)�F�+3�C��(�(��8�C��(�3�3�3�3��
�
�f�d�#�#�#�#�#s�A�Ac�^�d|j_|�|jjd��dS)Nzspam.pyc)rLrErRrHrs r�test_cached_sourcelessz&ModuleSpecTests.test_cached_sourceless�s-��)��
�������-�z�:�:�:�:�:rN)r#r$r%rNrXrZr^rarermrorrrtryr{r�r�r�r�r�r�r�rrrr?r?As1������+�+�+�	,�	,�	,�	,�	,�	,�
,�
,�
,�
,�
,�
,�+�+�+�	,�	,�	,�	/�	/�	/�	.�	.�	.�.�.�.�.�.�.�
3�3�3�)�)�)�)�)�)�
)�)�)�9�9�9�
2�2�2�
$�$�$�;�;�;�;�;rr?)rrJc�x�eZdZed���Zd�Zd�Zd�Zd�Zd�Z	d�Z
d�Zd	�Zd
�Z
d�Zd�Zd
�Zd�Zd�ZdS)�ModuleSpecMethodsTestsc��|jjSr	��init�
_bootstraprs r�	bootstrapz ModuleSpecMethodsTests.bootstrap��
���y�#�#rc�^�d|_d|_|j�|j��|_t��|_|j�|j|j��|_	|j�|j|j|j���|_
d|j
_dSrArFrs rrNzModuleSpecMethodsTests.setUp�rOrc�X�t��|j_|j�|j��}|t
j|j<|�t|d����|j
�|j|��|�|j
d��dS)Nr+r()r'r!rIr�module_from_specri�modulesrrV�hasattrr��_execrRr+r,s  r�	test_execz ModuleSpecMethodsTests.test_exec�s���$�;�;��	����+�+�D�I�6�6��!'���D�I��������0�0�1�1�1�����T�Y��/�/�/������a�(�(�(�(�(rc�p�t��|j_t|jj��5|j�|j��}tj|jj}ddd��n#1swxYwY|�	|j
d��|�||��dS�Nr()r'r!rIrrr��_loadrir�rRr+rS)r�loaded�	installeds   r�	test_loadz ModuleSpecMethodsTests.test_loads���$�;�;��	��
����
(�
(�	4�	4��^�)�)�$�)�4�4�F���D�I�N�3�I�	4�	4�	4�	4�	4�	4�	4�	4�	4�	4�	4����	4�	4�	4�	4�	
�����a�(�(�(��
�
�f�i�(�(�(�(�(s�<A:�:A>�A>c���t���G�fd�dt��}|��|j_t	|jj��5|j�|j��}tj	|jj}ddd��n#1swxYwY|�
|���|�
|���dS)Nc���eZdZ�fd�ZdS)�BModuleSpecMethodsTests.test_load_replaced.<locals>.ReplacingLoaderc�0���tj|j<dSr	)rir�r#)rr-�replacements  �rr.zNModuleSpecMethodsTests.test_load_replaced.<locals>.ReplacingLoader.exec_modules���/:���F�O�,�,�,rN�r#r$r%r.)r�s�r�ReplacingLoaderr�s.�������
;�
;�
;�
;�
;�
;�
;rr�)�objectrr!rIrrr�r�rir�rS)rr�r�r�r�s    @r�test_load_replacedz)ModuleSpecMethodsTests.test_load_replaceds����h�h��	;�	;�	;�	;�	;�	;�	;�j�	;�	;�	;�+�?�,�,��	��
����
(�
(�	4�	4��^�)�)�$�)�4�4�F���D�I�N�3�I�	4�	4�	4�	4�	4�	4�	4�	4�	4�	4�	4����	4�	4�	4�	4�	
�
�
�f�k�*�*�*��
�
�i��-�-�-�-�-s�<B�B�!Bc��Gd�dt��}|��|j_t|jj��5|�t��5|j�|j��}ddd��n#1swxYwY|�	|jjtj��ddd��dS#1swxYwYdS)Nc��eZdZd�ZdS)�=ModuleSpecMethodsTests.test_load_failed.<locals>.FailedLoaderc��t�r	)�RuntimeErrorr,s  rr.zIModuleSpecMethodsTests.test_load_failed.<locals>.FailedLoader.exec_modules��"�"rNr�rrr�FailedLoaderr�s#������
#�
#�
#�
#�
#rr��rr!rIrr�assertRaisesr�r�r��assertNotInrir��rr�r�s   r�test_load_failedz'ModuleSpecMethodsTests.test_load_failedsP��	#�	#�	#�	#�	#�:�	#�	#�	#�(�<�>�>��	��
����
(�
(�	:�	:��"�"�<�0�0�
9�
9���-�-�d�i�8�8��
9�
9�
9�
9�
9�
9�
9�
9�
9�
9�
9����
9�
9�
9�
9����T�Y�^�S�[�9�9�9�	:�	:�	:�	:�	:�	:�	:�	:�	:�	:�	:�	:����	:�	:�	:�	:�	:�	:�6�C
� B�<C
�B	�C
�B	�-C
�
C�Cc��Gd�dt��}|��|j_t|jj��5|�t��5|j�|j��}ddd��n#1swxYwY|�	|jjtj��ddd��dS#1swxYwYdS)Nc��eZdZd�ZdS)�EModuleSpecMethodsTests.test_load_failed_removed.<locals>.FailedLoaderc�4�tj|j=t�r	)rir�r#r�r,s  rr.zQModuleSpecMethodsTests.test_load_failed_removed.<locals>.FailedLoader.exec_module(s���K���0�"�"rNr�rrrr�r�'s#������
#�
#�
#�
#�
#rr�r�r�s   r�test_load_failed_removedz/ModuleSpecMethodsTests.test_load_failed_removed&sP��	#�	#�	#�	#�	#�:�	#�	#�	#�(�<�>�>��	��
����
(�
(�	:�	:��"�"�<�0�0�
9�
9���-�-�d�i�8�8��
9�
9�
9�
9�
9�
9�
9�
9�
9�
9�
9����
9�
9�
9�
9����T�Y�^�S�[�9�9�9�	:�	:�	:�	:�	:�	:�	:�	:�	:�	:�	:�	:����	:�	:�	:�	:�	:�	:r�c��tj��5tjdt��t	��|j_t|jj��5|j	�
|j��}ddd��n#1swxYwY|�|jd��ddd��dS#1swxYwYdS�Nr2r1)
r8r9r:�
ImportWarningr0r!rIrrr�r�rRr6�rr�s  r�test_load_legacyz'ModuleSpecMethodsTests.test_load_legacy1s.��
�
$�
&�
&�	-�	-��!�(�M�:�:�:�+�~�~�D�I���T�Y�^�,�,�
9�
9���-�-�d�i�8�8��
9�
9�
9�
9�
9�
9�
9�
9�
9�
9�
9����
9�
9�
9�
9�
���V�Z��,�,�,�
	-�	-�	-�	-�	-�	-�	-�	-�	-�	-�	-�	-����	-�	-�	-�	-�	-�	-s6�AB?�  B�B?�B	�B?�B	�B?�?C�Cc�6�tj��5tjdt��t	��|j_t|jj��5|j	�
|j��}ddd��n#1swxYwY|�|j|jj��|�
|j|jj��|�|j|j��ddd��dS#1swxYwYdS)Nr2)r8r9r:r�r0r!rIrrr�r�rS�
__loader__rR�__package__rx�__spec__r�s  r�test_load_legacy_attributesz2ModuleSpecMethodsTests.test_load_legacy_attributes:sh��
�
$�
&�
&�	6�	6��!�(�M�:�:�:�+�~�~�D�I���T�Y�^�,�,�
9�
9���-�-�d�i�8�8��
9�
9�
9�
9�
9�
9�
9�
9�
9�
9�
9����
9�
9�
9�
9�
�M�M�&�+�T�Y�-=�>�>�>����V�/���1A�B�B�B��M�M�&�/�4�9�5�5�5�	6�	6�	6�	6�	6�	6�	6�	6�	6�	6�	6�	6����	6�	6�	6�	6�	6�	6s7�AD�  B�D�B	�D�B	�A-D�D�Dc���t���tj��5tjdt��G�fd�dt
��}|��|j_t|jj	��5|j
�|j��}|�tj|jj	���ddd��n#1swxYwYddd��dS#1swxYwYdS)Nr2c���eZdZ�fd�ZdS)�UModuleSpecMethodsTests.test_load_legacy_attributes_immutable.<locals>.ImmutableLoaderc�&���tj|<�Sr	)rir�)rrr-s  �rr7zaModuleSpecMethodsTests.test_load_legacy_attributes_immutable.<locals>.ImmutableLoader.load_moduleJs���(.�C�K��%�!�MrN)r#r$r%r7)r-s�r�ImmutableLoaderr�Is.�������"�"�"�"�"�"�"rr�)r�r8r9r:r�rr!rIrrr�r�rSrir�)rr�r�r-s   @r�%test_load_legacy_attributes_immutablez<ModuleSpecMethodsTests.test_load_legacy_attributes_immutableEs��������
�
$�
&�
&�
	C�
	C��!�(�M�:�:�:�
"�
"�
"�
"�
"�
"�
"�*�
"�
"�
"� /��0�0�D�I���T�Y�^�,�,�
C�
C���-�-�d�i�8�8���
�
�c�k�$�)�.�9�6�B�B�B�
C�
C�
C�
C�
C�
C�
C�
C�
C�
C�
C����
C�
C�
C�
C�
	C�
	C�
	C�
	C�
	C�
	C�
	C�
	C�
	C�
	C�
	C�
	C����
	C�
	C�
	C�
	C�
	C�
	Cs7�AC4�AC�C4�C 	� C4�#C 	�$C4�4C8�;C8c���t��|j_t|jj��5|j�|j��}|j�|j|��}tj	|jj}ddd��n#1swxYwY|�
|jd��|�||��|�||��dSr�)
r'r!rIrrr�r�r�rir�rRr+rS�rr��reloadedr�s    r�test_reloadz"ModuleSpecMethodsTests.test_reloadUs���$�;�;��	��
����
(�
(�	4�	4��^�)�)�$�)�4�4�F��~�+�+�D�I�v�>�>�H���D�I�N�3�I�	4�	4�	4�	4�	4�	4�	4�	4�	4�	4�	4����	4�	4�	4�	4�
	
�����a�(�(�(��
�
�h��'�'�'��
�
�i��(�(�(�(�(s�AB�B�!Bc��t��|j_t|jj��5|j�|j��}d|_|j�|j|��}ddd��n#1swxYwY|�	|jd��|�
||��dS)N�r()r'r!rIrrr�r�r+r�rRrS�rr�r�s   r�test_reload_modifiedz+ModuleSpecMethodsTests.test_reload_modified`s���$�;�;��	��
����
(�
(�	?�	?��^�)�)�$�)�4�4�F��F�K��~�+�+�D�I�v�>�>�H�	?�	?�	?�	?�	?�	?�	?�	?�	?�	?�	?����	?�	?�	?�	?�
	
�����a�(�(�(��
�
�h��'�'�'�'�'��AB�B	�B	c��t��|j_t|jj��5|j�|j��}d|_|j�|j|��}ddd��n#1swxYwY|�	|j��|�
||��dS�NF)r'r!rIrrr�r��	availabler�rVrSr�s   r�test_reload_extra_attributesz3ModuleSpecMethodsTests.test_reload_extra_attributesjs���$�;�;��	��
����
(�
(�	?�	?��^�)�)�$�)�4�4�F�$�F���~�+�+�D�I�v�>�>�H�	?�	?�	?�	?�	?�	?�	?�	?�	?�	?�	?����	?�	?�	?�	?�
	
����)�*�*�*��
�
�h��'�'�'�'�'r�c� �t��|j_t|jj��5|j�|j��}d|_|`|`	|`
|j�|j|��ddd��n#1swxYwY|�|j|jj��|�
|j|jj��|�|j	|jj��|�
|j
|j��|�t!|d����|�t!|d����|�t!|d����dS)Nr6�__path__�__file__�
__cached__)r'r!rIrrr�r�r#r�r�r�r�rRrSrxrVr�r�s  r�test_reload_init_module_attrsz4ModuleSpecMethodsTests.test_reload_init_module_attrsts���$�;�;��	��
����
(�
(�	4�	4��^�)�)�$�)�4�4�F�#�F�O��!��"����N� � ���F�3�3�3�
	4�	4�	4�	4�	4�	4�	4�	4�	4�	4�	4����	4�	4�	4�	4�	
�����$�)�.�9�9�9��
�
�f�'���)9�:�:�:�����+�T�Y�-=�>�>�>��
�
�f�o�t�y�1�1�1�������4�4�5�5�5�������4�4�5�5�5�������6�6�7�7�7�7�7s�A
B�B�Bc�f�tj��5tjdt��t	��|j_t|jj��5|j	�
|j��}|j	�|j|��}tj
|jj}ddd��n#1swxYwYddd��n#1swxYwY|�|jd��|�||��|�||��dSr�)r8r9r:r�r0r!rIrrr�r�r�rir�rRr6rSr�s    r�test_reload_legacyz)ModuleSpecMethodsTests.test_reload_legacy�sv��
�
$�
&�
&�	8�	8��!�(�M�:�:�:�+�~�~�D�I���T�Y�^�,�,�
8�
8���-�-�d�i�8�8���>�/�/��	�6�B�B���K��	��7�	�
8�
8�
8�
8�
8�
8�
8�
8�
8�
8�
8����
8�
8�
8�
8�	8�	8�	8�	8�	8�	8�	8�	8�	8�	8�	8����	8�	8�	8�	8�	
�����R�(�(�(��
�
�h��'�'�'��
�
�i��(�(�(�(�(s7�AC� AC�<C�C	�C�C	�C�C#�&C#N)r#r$r%�propertyr�rNr�r�r�r�r�r�r�r�r�r�r�r�r�rrrr�r��s������
�$�$��X�$�+�+�+�)�)�)�)�)�)�.�.�.�:�:�:�	:�	:�	:�-�-�-�	6�	6�	6�C�C�C� 	)�	)�	)�(�(�(�(�(�(�8�8�8�$)�)�)�)�)rr�)r�rrJc�f�eZdZed���Zd�Zd�Zd�Zd�Zd�Z	d�Z
d�Zd	�Zd
�Z
d�Zd�Zd
S)�ModuleReprTestsc��|jjSr	r�rs rr�zModuleReprTests.bootstrap�r�rc��tt��d��|_|j�dt����|_dS)NrB)rh�osr-rJrKrr!rs rrNzModuleReprTests.setUp�s:���d�2�h�h�v�&�&����N�-�-�f�j�l�l�C�C��	�	�	rc��Gd�d��}|��|j_|j�|j��}|�|d��dS)Nc��eZdZd�ZdS)�BModuleReprTests.test_module___loader___module_repr.<locals>.Loaderc�6�d�|j��S)Nz<delicious {}>)�formatr#r,s  r�module_reprzNModuleReprTests.test_module___loader___module_repr.<locals>.Loader.module_repr�s��'�.�.�v��?�?�?rN�r#r$r%r�rrr�Loaderr��s(������
@�
@�
@�
@�
@rr�z<delicious spam>)r-r�r��_module_reprrR�rr��modreprs   r�"test_module___loader___module_reprz2ModuleReprTests.test_module___loader___module_repr�sx��	@�	@�	@�	@�	@�	@�	@�	@�"(��������.�-�-�d�k�:�:������"4�5�5�5�5�5rc���Gd�dt��}|��|j_|j�|j��}|�|d�d����dS)Nc��eZdZd�ZdS)�FModuleReprTests.test_module___loader___module_repr_bad.<locals>.Loaderc��t�r	)�	Exceptionr,s  rr�zRModuleReprTests.test_module___loader___module_repr_bad.<locals>.Loader.module_repr�s���rNr�rrrr�r��s#������
 �
 �
 �
 �
 rr��#<module {!r} (<TestLoader object>)>rB�rr-r�r�r�rRr�r�s   r�&test_module___loader___module_repr_badz6ModuleReprTests.test_module___loader___module_repr_bad�s���	 �	 �	 �	 �	 �Z�	 �	 �	 �"(��������.�-�-�d�k�:�:������>�E�E�f�M�M�	O�	O�	O�	O�	Orc���d}||j_|j|j_|j�|j��}|�|d�d|����dS)Nzin a hole, in the groundz<module {!r} ({})>rB)r!rEr-r�r�r�rRr�)rrEr�s   r�test_module___spec__z$ModuleReprTests.test_module___spec__�sa��+��!��	��#�y�����.�-�-�d�k�:�:������"6�"=�"=�f�f�"M�"M�N�N�N�N�Nrc���d}||j_d|j_|j|j_|j�|j��}|�|d�d|����dS)Nzin_a_galaxy_far_far_away.pyT�<module {!r} from {!r}>rB)	r!rErMr-r�r�r�rRr�)r�locationr�s   r�test_module___spec___locationz-ModuleReprTests.test_module___spec___location�sz��0��#��	��"&��	��#�y�����.�-�-�d�k�:�:������2�9�9�&�(�K�K�	M�	M�	M�	M�	Mrc���t��|j_|j|j_|j�|j��}|�|d�d����dS�Nr�rB)	rr!rIr-r�r�r�rRr��rr�s  r�test_module___spec___no_originz.ModuleReprTests.test_module___spec___no_origin�sm��%�<�<��	��#�y�����.�-�-�d�k�:�:������>�E�E�f�M�M�	O�	O�	O�	O�	Orc���d|j_|j|j_|j�|j��}|�|d�d����dS�N�
<module {!r}>rB)r!rIr-r�r�r�rRr�rs  r�(test_module___spec___no_origin_no_loaderz8ModuleReprTests.test_module___spec___no_origin_no_loader�sY����	��#�y�����.�-�-�d�k�:�:������/�"8�"8��"@�"@�A�A�A�A�Arc��|j`|j�|j��}|�|d�d����dS)Nr	�?)r-r#r�r�rRr�rs  r�test_module_no_namez#ModuleReprTests.test_module_no_name�sK���K� ��.�-�-�d�k�:�:������/�"8�"8��"=�"=�>�>�>�>�>rc��d}||j_|j�|j��}|�|d�d|����dS)Nze/i/e/i/o/spam.pyrrB)r-r�r�r�rRr�)r�filenamer�s   r�test_module_with_filez%ModuleReprTests.test_module_with_file�sd��&��'�����.�-�-�d�k�:�:������2�9�9�&�(�K�K�	M�	M�	M�	M�	Mrc���t��|j_|j�|j��}|�|d�d����dSrr�rs  r�test_module_no_filez#ModuleReprTests.test_module_no_file�sa��!+�������.�-�-�d�k�:�:������>�E�E�f�M�M�	O�	O�	O�	O�	Orc��|j�|j��}|�|d�d����dSr)r�r�r-rRr�rs  r�test_module_no_file_no_loaderz-ModuleReprTests.test_module_no_file_no_loader�sC���.�-�-�d�k�:�:������/�"8�"8��"@�"@�A�A�A�A�ArN)r#r$r%r�r�rNr�r�r�rrr
r
rrrrrrr�r��s�������
�$�$��X�$�D�D�D�6�6�6�O�O�O�O�O�O�M�M�M�O�O�O�B�B�B�?�?�?�M�M�M�O�O�O�B�B�B�B�Brr�c��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�ZdS)�FactoryTestsc�0�d|_tj�d��|_|j�|j��|_t��|_t|j��|_	t|jd��|_
dS)NrBrCT)rr�r
�abspathrrGrHrrI�
fileloader�	pkgloaderrs rrNzFactoryTests.setUp�sj����	��G�O�O�I�.�.��	��i�1�1�$�)�<�<��� �l�l���$�T�Y�/�/���#�D�I�t�4�4����rc���|j�|j|j��}|�|j|j��|�|j|j��|�|jd��|�|jd��|�|jd��|�|j	d��|�
|j��dSr	�r�spec_from_loaderrrIrRrSrErTrUrHrVrWr s  r�test_spec_from_loader_defaultz*FactoryTests.test_spec_from_loader_defaults����y�)�)�$�)�T�[�A�A�������D�I�.�.�.������d�k�2�2�2��
�
�d�k�4�(�(�(��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc��Gd�d��}|��}|j�|j|��}|�|j|j��|�|j|��|�|jd��|�|jd��|�|jd��|�|j	d��|�
|j��dS)Nc��eZdZd�ZdS)�NFactoryTests.test_spec_from_loader_default_with_bad_is_package.<locals>.Loaderc��t�r	��ImportErrorrs  rr
zYFactoryTests.test_spec_from_loader_default_with_bad_is_package.<locals>.Loader.is_package���!�!rN�r#r$r%r
rrrr�r!�#������
"�
"�
"�
"�
"rr�)rrrrRrIrSrErTrUrHrVrW�rr�rIr!s    r�1test_spec_from_loader_default_with_bad_is_packagez>FactoryTests.test_spec_from_loader_default_with_bad_is_packages���	"�	"�	"�	"�	"�	"�	"�	"�������y�)�)�$�)�V�<�<�������D�I�.�.�.������f�-�-�-��
�
�d�k�4�(�(�(��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���d}|j�|j|j|���}|�|j|j��|�|j|j��|�|j|��|�|jd��|�|jd��|�|j	d��|�
|j��dS)Nzsomewhere over the rainbowrDr�rrEr!s   r�test_spec_from_loader_originz)FactoryTests.test_spec_from_loader_origins���-���y�)�)�$�)�T�[�17�*�9�9��	
�����D�I�.�.�.������d�k�2�2�2��
�
�d�k�6�*�*�*��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���|j�|j|jd���}|�|j|j��|�|j|j��|�|jd��|�|jd��|�|jd��|�|j	d��|�
|j��dSr\rr s  r�&test_spec_from_loader_is_package_falsez3FactoryTests.test_spec_from_loader_is_package_false,s����y�)�)�$�)�T�[�5:�*�<�<��	
�����D�I�.�.�.������d�k�2�2�2��
�
�d�k�4�(�(�(��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���|j�|j|jd���}|�|j|j��|�|j|j��|�|jd��|�|jd��|�|jg��|�|j	d��|�
|j��dSr`rr s  r�%test_spec_from_loader_is_package_truez2FactoryTests.test_spec_from_loader_is_package_true8s����y�)�)�$�)�T�[�59�*�;�;��	
�����D�I�.�.�.������d�k�2�2�2��
�
�d�k�4�(�(�(��
�
�d�'��.�.�.�����8�"�=�=�=��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���d}|j�|j|j|d���}|�|j|j��|�|j|j��|�|j|��|�|jd��|�|jg��|�|j	d��|�
|j��dS)Nzwhere the streets have no nameT)rEr
rr+s   r�+test_spec_from_loader_origin_and_is_packagez8FactoryTests.test_spec_from_loader_origin_and_is_packageDs���1���y�)�)�$�)�T�[�17�D�*�J�J��	
�����D�I�.�.�.������d�k�2�2�2��
�
�d�k�6�*�*�*��
�
�d�'��.�.�.�����8�"�=�=�=��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���td���}|j�|j|��}|�|j|j��|�|j|��|�|jd��|�|jd��|�|j	d��|�|j
d��|�|j��dSr\�
rrrrrRrIrSrErTrUrHrVrW�rrIr!s   r�2test_spec_from_loader_is_package_with_loader_falsez?FactoryTests.test_spec_from_loader_is_package_with_loader_falseQs����u�-�-�-���y�)�)�$�)�V�<�<�������D�I�.�.�.������f�-�-�-��
�
�d�k�4�(�(�(��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���td���}|j�|j|��}|�|j|j��|�|j|��|�|jd��|�|jd��|�|j	g��|�|j
d��|�|j��dSr`r4r5s   r�1test_spec_from_loader_is_package_with_loader_truez>FactoryTests.test_spec_from_loader_is_package_with_loader_true]s����t�,�,�,���y�)�)�$�)�V�<�<�������D�I�.�.�.������f�-�-�-��
�
�d�k�4�(�(�(��
�
�d�'��.�.�.�����8�"�=�=�=��
�
�d�k�4�(�(�(�����*�+�+�+�+�+rc���|j�|j|j��}|�|j|j��|�|j|j��|�|j|j��|�|j	d��|�|j
d��|�|j|j��|�|j
��dSr	�rrrrrRrIrEr
rSrTrUrHrdrWr s  r�.test_spec_from_loader_default_with_file_loaderz;FactoryTests.test_spec_from_loader_default_with_file_loaderis����y�)�)�$�)�T�_�E�E�������D�I�.�.�.������d�o�6�6�6������d�i�0�0�0��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<������d�k�2�2�2�����)�*�*�*�*�*rc���|j�|j|jd���}|�|j|j��|�|j|j��|�|j|j��|�|j	d��|�|j
d��|�|j|j��|�|j
��dSr\r:r s  r�6test_spec_from_loader_is_package_false_with_fileloaderzCFactoryTests.test_spec_from_loader_is_package_false_with_fileloaderts����y�)�)�$�)�T�_�5:�*�<�<��	
�����D�I�.�.�.������d�o�6�6�6������d�i�0�0�0��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<������d�k�2�2�2�����)�*�*�*�*�*rc��|j�|j|jd���}|�|j|j��|�|j|j��|�|j|j��|�|j	d��|�|j
tj��g��|�|j
|j
��|�|j��dSr`)rrrrrRrIrEr
rSrTrUr��getcwdrHrdrWr s  r�5test_spec_from_loader_is_package_true_with_fileloaderzBFactoryTests.test_spec_from_loader_is_package_true_with_fileloader�s����y�)�)�$�)�T�_�59�*�;�;��	
�����D�I�.�.�.������d�o�6�6�6������d�i�0�0�0��
�
�d�'��.�.�.�����8�2�9�;�;�-�H�H�H������d�k�2�2�2�����)�*�*�*�*�*rc��|j�|j|j��}|�|j|j��|jjjd}|�|j|��|�|jj|j��|�|jj|j��|�|j|j��|�	|j
d��|�	|jd��|�|j|j��|�
|j��dS)N�SourceFileLoader)r�spec_from_file_locationrr
rR�__globals__�assertIsInstancerIrErSrTrUrHrdrW)rr!rBs   r�$test_spec_from_file_location_defaultz1FactoryTests.test_spec_from_file_location_default�s���y�0�0���D�I�F�F�������D�I�.�.�.� �9�<�H�I[�\�����d�k�+;�<�<�<������)�4�9�5�5�5������)�4�9�5�5�5������d�i�0�0�0��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<������d�k�2�2�2�����)�*�*�*�*�*rc��|j�|jtj|j����}|�|j|j��dSr	)rrCr�pathlib�PurePathr
rRrEr s  r�*test_spec_from_file_location_path_like_argz7FactoryTests.test_spec_from_file_location_path_like_arg�sO���y�0�0���18�1A�$�)�1L�1L�N�N�������d�i�0�0�0�0�0rc�p�|j�|j��}|�|d��dSr	�rrCrrSr s  r�5test_spec_from_file_location_default_without_locationzBFactoryTests.test_spec_from_file_location_default_without_location�s3���y�0�0���;�;���
�
�d�D�!�!�!�!�!rc�r�|j�|jd��}|�|d��dS)NrvrLr s  r�/test_spec_from_file_location_default_bad_suffixz<FactoryTests.test_spec_from_file_location_default_bad_suffix�s5���y�0�0���K�H�H���
�
�d�D�!�!�!�!�!rc���|j�|j|j���}|�|j|j��|�|j|j��|�|j|j��|�|j	d��|�|j
d��|�|j|j��|�|j
��dS�N�rI)rrCrrrRrIrEr
rSrTrUrHrdrWr s  r�/test_spec_from_file_location_loader_no_locationz<FactoryTests.test_spec_from_file_location_loader_no_location�s����y�0�0���8<��1�I�I��	
�����D�I�.�.�.������d�o�6�6�6������d�i�0�0�0��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<������d�k�2�2�2�����)�*�*�*�*�*rc���|j�|j|j���}|�|j|j��|�|j|j��|�|jd��|�|jd��|�|jd��|�|j	d��|�
|j��dS)NrR�	<unknown>)rrCrrIrRrErSrTrUrHrdrWr s  r�?test_spec_from_file_location_loader_no_location_no_get_filenamezLFactoryTests.test_spec_from_file_location_loader_no_location_no_get_filename�s����y�0�0���8<��1�E�E��	
�����D�I�.�.�.������d�k�2�2�2������k�2�2�2��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<��
�
�d�k�4�(�(�(�����)�*�*�*�*�*rc��Gd�d��}|��}|j�|j|���}|�|j|j��|�|j|��|�|jd��|�|jd��|�|jd��|�|j	d��|�
|j��dS)Nc��eZdZd�ZdS)�]FactoryTests.test_spec_from_file_location_loader_no_location_bad_get_filename.<locals>.Loaderc��t�r	r#rs  rrzjFactoryTests.test_spec_from_file_location_loader_no_location_bad_get_filename.<locals>.Loader.get_filename�r%rN)r#r$r%rrrrr�rY�r'rr�rRrU)rrCrrRrIrErSrTrUrHrdrWr(s    r�@test_spec_from_file_location_loader_no_location_bad_get_filenamezMFactoryTests.test_spec_from_file_location_loader_no_location_bad_get_filename�s���	"�	"�	"�	"�	"�	"�	"�	"�������y�0�0���6�0�J�J�������D�I�.�.�.������f�-�-�-������k�2�2�2��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<��
�
�d�k�4�(�(�(�����)�*�*�*�*�*rc��|j�|j|j|jd���}|�|j|j��|�|j|j��|�|j|j��|�|j	d��|�|j
d��|�|j|j��|�|j
��dS�N�rIrU�rrCrr
rrRrIrErSrTrUrHrdrWr s  r�&test_spec_from_file_location_smsl_nonez3FactoryTests.test_spec_from_file_location_smsl_none�s����y�0�0���D�I�.2�o�BF�1�H�H��	
�����D�I�.�.�.������d�o�6�6�6������d�i�0�0�0��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<������d�k�2�2�2�����)�*�*�*�*�*rc�$�|j�|j|j|jg���}|�|j|j��|�|j|j��|�|j|j��|�|j	d��|�|j
tj��g��|�|j
|j
��|�|j��dSr])rrCrr
rrRrIrErSrTrUr�r?rHrdrWr s  r�'test_spec_from_file_location_smsl_emptyz4FactoryTests.test_spec_from_file_location_smsl_empty�s����y�0�0���D�I�.2�o�BD�1�F�F��	
�����D�I�.�.�.������d�o�6�6�6������d�i�0�0�0��
�
�d�'��.�.�.�����8�2�9�;�;�-�H�H�H������d�k�2�2�2�����)�*�*�*�*�*rc��|j�|j|j|jdg���}|�|j|j��|�|j|j��|�|j|j��|�|j	d��|�|j
dg��|�|j|j��|�|j
��dS)Nr+r^r_r s  r�+test_spec_from_file_location_smsl_not_emptyz8FactoryTests.test_spec_from_file_location_smsl_not_empty�s����y�0�0���D�I�.2�o�CI�(�1�L�L��	
�����D�I�.�.�.������d�o�6�6�6������d�i�0�0�0��
�
�d�'��.�.�.�����8�6�(�C�C�C������d�k�2�2�2�����)�*�*�*�*�*rc�"�|j�|j|j|j���}|�|j|j��|�|j|j��|�|j|j��|�|j	d��|�|j
tj��g��|�|j
|j
��|�|j��dSrQ)rrCrr
rrRrIrErSrTrUr�r?rHrdrWr s  r�)test_spec_from_file_location_smsl_defaultz6FactoryTests.test_spec_from_file_location_smsl_default�s����y�0�0���D�I�.2�n�1�>�>��	
�����D�I�.�.�.������d�n�5�5�5������d�i�0�0�0��
�
�d�'��.�.�.�����8�2�9�;�;�-�H�H�H������d�k�2�2�2�����)�*�*�*�*�*rc��Gd�d��}|��}|j�|j|j|���}|�|j|j��|�|j|��|�|j|j��|�|jd��|�|j	d��|�|j
|j
��|�|j��dS)Nc��eZdZd�ZdS)�RFactoryTests.test_spec_from_file_location_smsl_default_not_package.<locals>.Loaderc��dSr�rrs  rr
z]FactoryTests.test_spec_from_file_location_smsl_default_not_package.<locals>.Loader.is_package
s���urNr&rrrr�ri	s#������
�
�
�
�
rr�rR�
rrCrr
rRrIrErSrTrUrHrdrWr(s    r�5test_spec_from_file_location_smsl_default_not_packagezBFactoryTests.test_spec_from_file_location_smsl_default_not_packages��	�	�	�	�	�	�	�	�������y�0�0���D�I�8>�1�@�@��	
�����D�I�.�.�.������f�-�-�-������d�i�0�0�0��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<������d�k�2�2�2�����)�*�*�*�*�*rc��|j�|j|j|j���}|�|j|j��|�|j|j��|�|j|j��|�|j	d��|�|j
d��|�|j|j��|�|j
��dSrQr_r s  r�7test_spec_from_file_location_smsl_default_no_is_packagezDFactoryTests.test_spec_from_file_location_smsl_default_no_is_packages����y�0�0���D�I�.2�o�1�?�?��	
�����D�I�.�.�.������d�o�6�6�6������d�i�0�0�0��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<������d�k�2�2�2�����)�*�*�*�*�*rc��Gd�d��}|��}|j�|j|j|���}|�|j|j��|�|j|��|�|j|j��|�|jd��|�|j	d��|�|j
|j
��|�|j��dS)Nc��eZdZd�ZdS)�UFactoryTests.test_spec_from_file_location_smsl_default_bad_is_package.<locals>.Loaderc��t�r	r#rs  rr
z`FactoryTests.test_spec_from_file_location_smsl_default_bad_is_package.<locals>.Loader.is_package&r%rNr&rrrr�rq%r'rr�rRrkr(s    r�8test_spec_from_file_location_smsl_default_bad_is_packagezEFactoryTests.test_spec_from_file_location_smsl_default_bad_is_package$s��	"�	"�	"�	"�	"�	"�	"�	"�������y�0�0���D�I�8>�1�@�@��	
�����D�I�.�.�.������f�-�-�-������d�i�0�0�0��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<������d�k�2�2�2�����)�*�*�*�*�*rc�8�|j�|jtj�|j��|j���}|�|j|j��|�|j|j��|�|j	|j��|�
|jd��|�
|jd��|�|j
|j
��|�|j��dSrQ)rrCrr�r
�basenamerrRrIrErSrTrUrHrdrWr s  r�*test_spec_from_file_location_relative_pathz7FactoryTests.test_spec_from_file_location_relative_path4s����y�0�0����G���T�Y�'�'���1�A�A��	
�����D�I�.�.�.������d�o�6�6�6������d�i�0�0�0��
�
�d�'��.�.�.��
�
�d�5�t�<�<�<������d�k�2�2�2�����)�*�*�*�*�*rN)r#r$r%rNrr)r,r.r0r2r6r8r;r=r@rFrJrMrOrSrVr[r`rbrdrfrlrnrsrvrrrrr�s�������5�5�5�	,�	,�	,�
,�
,�
,�,�,�,�
,�
,�
,�
,�
,�
,�,�,�,�
,�
,�
,�
,�
,�
,�	+�	+�	+�
+�
+�
+�
+�
+�
+�+�+�+�"1�1�1�
"�"�"�
"�"�"�

+�
+�
+�
+�
+�
+�
+�
+�
+�+�+�+�+�+�+�+�+�+�
+�
+�
+�+�+�+� 
+�
+�
+�+�+�+� 
+�
+�
+�
+�
+rr�__main__) �test.test_importlibr�	test_util�import_importlibr�rJ�os.pathr�rH�test.support.import_helperr�unittestrir8rr'r0r?�	test_both�Frozen_ModuleSpecTests�Source_ModuleSpecTestsr��Frozen_ModuleSpecMethodsTests�Source_ModuleSpecMethodsTestsr��Frozen_ModuleReprTests�Source_ModuleReprTestsr�Frozen_FactoryTests�Source_FactoryTestsr#�mainrrr�<module>r�s���1�1�1�1�1�1�!�y�!�+�.�.��&�I�&�'<�=�=�	�!�y�!�"2�3�3����������2�2�2�2�2�2�����
�
�
�
�������������4 � � � � �
� � � ������:����`;�`;�`;�`;�`;�`;�`;�`;�J�Y���t�y�I�I�I����h)�h)�h)�h)�h)�h)�h)�h)�Z�Y��/�d��#,�.�.�.����
VB�VB�VB�VB�VB�VB�VB�VB�v�Y���t�$�#,�.�.�.����
E+�E+�E+�E+�E+�E+�E+�E+�R
�Y���D�I�F�F�F�����z����H�M�O�O�O�O�O��r