efddlZddlZddlZddlZddlZddlZddlmZmZddl m Z ddlm Z ddl m Z mZmZmZmZmZmZddlmZddlmZdd lmZdd lmZGd d e ZGd dZGddeZdS)N)DistutilsErrorDistutilsOptionError)log) TestLoader)resource_listdirresource_existsnormalize_path working_setevaluate_markeradd_activation_listenerrequire)metadata)Command)unique_everseen) pass_noneceZdZdZddZdS)ScanningLoadercTtj|t|_dSN)r__init__set_visitedselfs w/builddir/build/BUILD/imunify360-venv-2.3.5/opt/imunify360/venv/lib/python3.11/site-packages/setuptools/command/test.pyrzScanningLoader.__init__s"D!!! Nc||jvrdS|j|g}|tj||t |dr'||t |drt|jdD]}| dr|dkr|jdz|ddz}n't|j|d zr|jdz|z}nZ|| |t|d kr| |S|d S) 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. Nadditional_tests__path__z.pyz __init__.py.z /__init__.pyr)raddappendrloadTestsFromModulehasattrrr__name__endswithrloadTestsFromNamelen suiteClass)rmodulepatterntestsfile submodules rr'z"ScanningLoader.loadTestsFromModulesf T] " "4 &!!! Z3D&AABBB 6- . . 4 LL0022 3 3 3 6: & & @("== @ @==''!DM,A,A &# 5SbS AII&v~8MNN!$*Oc$9D$@   T33I>>???? u::????5)) )8Orr)r) __module__ __qualname__rr'rrrrs7rrceZdZdZddZdS)NonDataPropertyc||_dSrfget)rr:s rrzNonDataProperty.__init__Cs  rNc4||S||Srr9)robjobjtypes r__get__zNonDataProperty.__get__Fs ;Kyy~~rr)r)r3r4rr>r5rrr7r7Bs7rr7ceZdZdZdZgdZdZdZedZ dZ dZ e j gfd Zee j d Zed Zd Zd ZedZeedZdS)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)z test-suite=sz9Run single test, case or suite (e.g. 'module.test_suite'))z test-runner=rzTest runner to usec>d|_d|_d|_d|_dSr) test_suite test_module test_loader test_runnerrs rinitialize_optionsztest.initialize_options[s'rcJ|jr|jrd}t||j(|j|jj|_n|jdz|_|jt |jdd|_|jd|_|jt |jdd|_dSdS)Nz1You may specify a module or a suite, but not bothz .test_suiterGz&setuptools.command.test:ScanningLoaderrH)rErFr distributionrGgetattrrH)rmsgs rfinalize_optionsztest.finalize_optionsas ? ,t/ ,EC&s++ + ? "'"&"3">"&"2]"B   #&t'8-NND    #GD    #&t'8-NND    $ #rcDt|Sr)list _test_argsrs r test_argsztest.test_argsssDOO%%&&&rc#ZK|jsdV|jrdV|jr |jVdSdS)Ndiscoverz --verbose)rEverbosers rrQztest._test_argswsZ     <     ? "/ ! ! ! ! ! " "rct|5|ddddS#1swxYwYdS)zI Backward compatibility for project_on_sys_path context. N)project_on_sys_path)rfuncs rwith_project_on_sys_pathztest.with_project_on_sys_paths % % ' '   DFFF                  s -11c#K|d|dd|d|d}tjdd}tj} t|j}tj d|tj tdt|jd|j||g5dVdddn #1swxYwY|tjdd<tjtj|tj dS#|tjdd<tjtj|tj wxYw)Negg_info build_extr$)inplacerc*|Sr)activate)dists rz*test.project_on_sys_path..srz==) run_commandreinitialize_commandget_finalized_commandsyspathmodulescopyr egg_baseinsertr rr r egg_name egg_versionpaths_on_pythonpathclearupdate)r include_distsei_cmdold_path old_modules project_paths rrWztest.project_on_sys_paths $$$ !!+q!999 %%%++J778AAA;k&&((  #)&/::L HOOA| , , ,  " " " #$@$@ A A A 1C1CD E E E))<.99                 #CHQQQK K      K  { + + +  " " " " "#CHQQQK K      K  { + + +  " " " "s2 B FD( F(D,,F/D,0FA#G9c#hKt}tjd|}tjdd} tjt |}td||g}tj|}|r|tjd<dV||ur"tjdddS|tjd<dS#||ur!tjddn|tjd<wxYw)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. PYTHONPATHr!N) objectosenvirongetpathsepjoinrfilterpop)pathsnothingorig_pythonpathcurrent_pythonpathprefixto_joinnew_paths rrmztest.paths_on_pythonpaths((*..w??Z^^L"== ;Z___U%;%;<#?@@Gzw//H 4+3 <( EEE')) |T22222+: <(((')) |T2222+: <(::::s A2C;;6D1c||j}||jpg}|d|jD}t j|||S)z Install the requirements indicated by self.distribution and return an iterable of the dists that were built. c3xK|]5\}}|dt|dd1|V6dS):r$N) startswithr ).0kvs r z%test.install_dists..sf% % 1||C  % &5QqrrU%;%;% % % % % % % r)fetch_build_eggsinstall_requires tests_requireextras_requireitems itertoolschain)r`ir_dtr_der_ds r install_distsztest.install_distss $$T%:;;$$T%7%=2>>$$% % +1133% % %    tT4000rc@|dtj||j}d|j}|jr|d|zdS|d|zttj d|}| |5| 5| dddn #1swxYwYddddS#1swxYwYdS)NzWARNING: 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)announcerWARNrrKr|_argvdry_runmapoperator attrgetterrmrW run_tests)rinstalled_distscmdrs rrunztest.runs   H    ,,T->??hhtz"" <  MM3c9 : : : F ns*+++H' 33_EE  % %e , , ! !))++ ! !    ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! !s6DC;/ D;C? ?DC? DDDc Htjdd|j||j||jd}|js9d|jz}||tj t|dS)NF) testLoader testRunnerexitzTest failed: %s) unittestmainr_resolve_as_eprGrHresult wasSuccessfulrrERRORr)rr@rMs rrztest.run_testss}   J**4+;<<**4+;<<    {((** &#dk1C MM#sy ) ) ) %% % & &rcdg|jzS)Nr)rRrs rrz test._argvs|dn,,rcdtj|ddS)zu Load the indicated attribute value, called, as a as if it were specified as an entry point. N)valuenamegroup)r EntryPointload)vals rrztest._resolve_as_eps1Lx"4tDDDIIKKMMMrN)r)r3r4__doc__ description user_optionsrIrNr7rRrQrY contextlibcontextmanagerrW staticmethodrmrrrpropertyrrrr5rrr@r@LsX88DKL   OOO$''_'"""02####4;;\;0 1 1\ 1!!!. & & &--X-NNY\NNNrr@)rxrrerrrdistutils.errorsrr distutilsrr pkg_resourcesrrr r r r r _importlibr setuptoolsr setuptools.extern.more_itertoolsr"setuptools.extern.jaraco.functoolsrrr7r@r5rrrs  AAAAAAAA"!!!!!<<<<<<888888$$$$$Z$$$PnNnNnNnNnN7nNnNnNnNnNr