https://t.me/AnonymousX5
Server : Apache
System : Linux cvar2.toservers.com 3.10.0-962.3.2.lve1.5.73.el7.x86_64 #1 SMP Wed Aug 24 21:31:23 UTC 2022 x86_64
User : njnconst ( 1116)
PHP Version : 8.4.18
Disable Function : NONE
Directory :  /opt/alt/python39/lib/python3.9/site-packages/setuptools/command/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //opt/alt/python39/lib/python3.9/site-packages/setuptools/command/__pycache__/test.cpython-39.pyc
a

�5�a��@s�ddlZddlZddlZddlZddlZddlZddlmZmZddl	m
Z
ddlmZddlm
Z
mZmZmZmZmZmZmZddlmZddlmZGdd	�d	e�ZGd
d�d�ZGdd
�d
e�ZdS)�N)�DistutilsError�DistutilsOptionError)�log)�
TestLoader)�resource_listdir�resource_exists�normalize_path�working_set�evaluate_marker�add_activation_listener�require�
EntryPoint)�Command)�unique_everseenc@seZdZdd�Zddd�ZdS)�ScanningLoadercCst�|�t�|_dS�N)r�__init__�set�_visited��self�r�H/opt/alt/python39/lib/python3.9/site-packages/setuptools/command/test.pyrs
zScanningLoader.__init__NcCs�||jvrdS|j�|�g}|�t�||��t|d�rH|�|���t|d�r�t|jd�D]`}|�	d�r�|dkr�|jd|dd�}n"t
|j|d	�r^|jd|}nq^|�|�|��q^t|�d
kr�|�
|�S|dSdS)aReturn a suite of all tests cases contained in the given module

        If the module is a package, load tests from all the modules in it.
        If the module has an ``additional_tests`` function, call it and add
        the return value to the tests.
        N�additional_tests�__path__�z.pyz__init__.py�.���z/__init__.py�r)r�add�appendr�loadTestsFromModule�hasattrrr�__name__�endswithrZloadTestsFromName�lenZ
suiteClass)r�module�patternZtests�fileZ	submodulerrrr!s$



z"ScanningLoader.loadTestsFromModule)N)r#�
__module__�__qualname__rr!rrrrrsrc@seZdZdd�Zddd�ZdS)�NonDataPropertycCs
||_dSr��fget)rr-rrrrBszNonDataProperty.__init__NcCs|dur|S|�|�Srr,)r�objZobjtyperrr�__get__EszNonDataProperty.__get__)N)r#r)r*rr/rrrrr+Asr+c@s�eZdZdZdZgd�Zdd�Zdd�Zedd	��Z	d
d�Z
dd
�Zej
gfdd��Zeej
dd���Zedd��Zdd�Zdd�Zedd��Zedd��ZdS)�testz.Command to run unit tests after in-place buildz0run unit tests after in-place build (deprecated)))ztest-module=�mz$Run 'test_suite' in specified module)ztest-suite=�sz9Run single test, case or suite (e.g. 'module.test_suite'))ztest-runner=�rzTest runner to usecCsd|_d|_d|_d|_dSr)�
test_suite�test_module�test_loader�test_runnerrrrr�initialize_optionsZsztest.initialize_optionscCs�|jr|jrd}t|��|jdurD|jdur8|jj|_n|jd|_|jdur^t|jdd�|_|jdurnd|_|jdur�t|jdd�|_dS)Nz1You may specify a module or a suite, but not bothz.test_suiter6z&setuptools.command.test:ScanningLoaderr7)r4r5r�distributionr6�getattrr7)r�msgrrr�finalize_options`s




ztest.finalize_optionscCst|���Sr)�list�
_test_argsrrrr�	test_argsssztest.test_argsccs4|jstjdkrdV|jr"dV|jr0|jVdS)N)��Zdiscoverz	--verbose)r4�sys�version_info�verboserrrrr>wsztest._test_argscCs2|���|�Wd�n1s$0YdS)zI
        Backward compatibility for project_on_sys_path context.
        N)�project_on_sys_path)r�funcrrr�with_project_on_sys_paths
ztest.with_project_on_sys_pathc
cs|�d�|jddd�|�d�|�d�}tjdd�}tj��}z�t|j�}tj�	d|�t
��tdd��t
d|j|jf�|�|g��dVWd�n1s�0YW|tjdd�<tj��tj�|�t
��n.|tjdd�<tj��tj�|�t
��0dS)	NZegg_infoZ	build_extr)ZinplacercSs|��Sr)Zactivate)�distrrr�<lambda>��z*test.project_on_sys_path.<locals>.<lambda>z%s==%s)Zrun_commandZreinitialize_commandZget_finalized_commandrB�path�modules�copyrZegg_base�insertr	rrrZegg_nameZegg_version�paths_on_pythonpath�clear�update)rZ
include_distsZei_cmdZold_pathZold_modulesZproject_pathrrrrE�s,




&

�
ztest.project_on_sys_pathc
cs�t�}tj�d|�}tj�dd�}zdtj�t|��}td||g�}tj�|�}|r\|tjd<dVW||ur|tj�dd�q�|tjd<n$||ur�tj�dd�n
|tjd<0dS)z�
        Add the indicated paths to the head of the PYTHONPATH environment
        variable so that subprocesses will also see the packages at
        these paths.

        Do this in a context that restores the value on exit.
        Z
PYTHONPATHrN)	�object�os�environ�get�pathsep�joinr�filter�pop)�pathsZnothingZorig_pythonpathZcurrent_pythonpath�prefixZto_join�new_pathrrrrO�s 

�ztest.paths_on_pythonpathcCsD|�|j�}|�|jpg�}|�dd�|j��D��}t�|||�S)z�
        Install the requirements indicated by self.distribution and
        return an iterable of the dists that were built.
        css0|](\}}|�d�rt|dd��r|VqdS)�:rN)�
startswithr
)�.0�k�vrrr�	<genexpr>�s�z%test.install_dists.<locals>.<genexpr>)Zfetch_build_eggsZinstall_requiresZ
tests_requireZextras_require�items�	itertools�chain)rHZir_dZtr_dZer_drrr�
install_dists�s
�ztest.install_distsc	Cs�|�dtj�|�|j�}d�|j�}|jr>|�d|�dS|�d|�tt	�
d�|�}|�|��@|���|�
�Wd�n1s�0YWd�n1s�0YdS)Nz�WARNING: Testing via this command is deprecated and will be removed in a future version. Users looking for a generic test entry point independent of test runner are encouraged to use tox.� zskipping "%s" (dry run)zrunning "%s"�location)�announcerZWARNrfr9rW�_argvZdry_run�map�operator�
attrgetterrOrE�	run_tests)rZinstalled_dists�cmdrZrrr�run�s�
ztest.runcCsVtjdd|j|�|j�|�|j�dd�}|j��sRd|j}|�|t	j
�t|��dS)NF)Z
testLoaderZ
testRunner�exitzTest failed: %s)�unittest�mainrj�_resolve_as_epr6r7�resultZ
wasSuccessfulrirZERRORr)rr0r;rrrrn�s

�

ztest.run_testscCsdg|jS)Nrr)r?rrrrrj�sz
test._argvcCs$|durdSt�d|�}|���S)zu
        Load the indicated attribute value, called, as a as if it were
        specified as an entry point.
        Nzx=)r
�parse�resolve)�val�parsedrrrrt�sztest._resolve_as_epN)r#r)r*�__doc__�descriptionZuser_optionsr8r<r+r?r>rG�
contextlib�contextmanagerrE�staticmethodrOrfrprn�propertyrjrtrrrrr0Ks,



r0)rSrlrBr|rdrrZdistutils.errorsrrZ	distutilsrrZ
pkg_resourcesrrrr	r
rrr
Z
setuptoolsrZ setuptools.extern.more_itertoolsrrr+r0rrrr�<module>s(
(

https://t.me/AnonymousX5 - 2025