§ 1j ãó@—dZddlZddlZdgZd„ZGd„d¦«ZdS)aa Pytest test running. This module implements the ``test()`` function for NumPy modules. The usual boiler plate for doing that is to put the following in the module ``__init__.py`` file:: from numpy._pytesttester import PytestTester test = PytestTester(__name__) del PytestTester Warnings filtering and other runtime settings should be dealt with in the ``pytest.ini`` file in the numpy repo root. The behavior of the test depends on whether or not that file is found as follows: * ``pytest.ini`` is present (develop mode) All warnings except those explicitly filtered out are raised as error. * ``pytest.ini`` is absent (release mode) DeprecationWarnings and PendingDeprecationWarnings are ignored, other warnings are passed through. In practice, tests run from the numpy repo are run in develop mode. That includes the standard ``python runtests.py`` invocation. This module is imported by every numpy subpackage, so lies at the top level to simplify circular import issues. For the same reason, it contains no numpy imports at module scope, instead importing numpy within function calls. éNÚ PytestTestercó—ddl}td|jz¦«| dd¬¦«jj}td|¦«|jj ¦«}td|r|nd¦«dS) NrzNumPy version %s)é éÚC)Úorderz&NumPy relaxed strides checking option:zNumPy CPU features: znothing enabled) ÚnumpyÚprintÚ __version__ÚonesÚflagsÚ f_contiguousÚlibÚutilsÚ _opt_info)ÚnpÚrelaxed_stridesÚinfos úJ/opt/cloudlinux/venv/lib64/python3.11/site-packages/numpy/_pytesttester.pyÚ_show_numpy_infor$s†€ØÐÐÐå Ð ˜rœ~Ñ -Ñ.Ô.Ð.Ø—g’g˜g¨S�gÑ1Ô1Ô7ÔD€OÝ Ð 2°OÑDÔDÐDØ Œ6Œ<× !Ò !Ñ #Ô #€DÝ Ð ¨4Ð#F 4 4Ð5FÑHÔHÐHÐHÐHócó$—eZdZdZd„Z d d„ZdS) raÇ Pytest test runner. A test function is typically added to a package's __init__.py like so:: from numpy._pytesttester import PytestTester test = PytestTester(__name__).test del PytestTester Calling this test function finds and runs all tests associated with the module and all its sub-modules. Attributes ---------- module_name : str Full path to the package to test. Parameters ---------- module_name : module name The name of the module to test. Notes ----- Unlike the previous ``nose``-based implementation, this class is not publicly exposed as it performs some ``numpy``-specific warning suppression. có—||_dS)N)Ú module_name)Úselfrs rÚ__init__zPytestTester.__init__Ls€Ø&ˆÔÐÐrÚfastrNFéÿÿÿÿcór—ddl}ddl} tj|j} t j | jd¦«} dg} | dgz } |   ¦«5|   d¦«ddl m } ddd¦«n #1swxYwY|   d¬¦«5ddl }ddd¦«n #1swxYwY| gd ¢z } | d d gz } |r| d gz } |r| t|¦«z } |d kr| dd|d z zzgz } |r | d| zgz } |dkrddlm}|r| ddgz } n| ddgz } n |dkr| d|gz } |dkr | d|zgz } |€|jg}| dgt|¦«zz } t#¦« | | ¦«}n#t&$r}|j}Yd}~nd}~wwxYw|dkS)a Run tests for module using pytest. Parameters ---------- label : {'fast', 'full'}, optional Identifies the tests to run. When set to 'fast', tests decorated with `pytest.mark.slow` are skipped, when 'full', the slow marker is ignored. verbose : int, optional Verbosity value for test outputs, in the range 1-3. Default is 1. extra_argv : list, optional List with any extra arguments to pass to pytests. doctests : bool, optional .. note:: Not supported coverage : bool, optional If True, report coverage of NumPy code. Default is False. Requires installation of (pip) pytest-cov. durations : int, optional If < 0, do nothing, If 0, report time of all tests, if > 0, report the time of the slowest `timer` tests. Default is -1. tests : test or list of tests Tests to be executed with pytest '--pyargs' Returns ------- result : bool Return True on success, false otherwise. Notes ----- Each NumPy module exposes `test` in its namespace to run all tests for it. For example, to run all tests for numpy.lib: >>> np.lib.test() #doctest: +SKIP Examples -------- >>> result = np.lib.test() #doctest: +SKIP ... 1023 passed, 2 skipped, 6 deselected, 1 xfailed in 10.39 seconds >>> result True rNz-lz-qÚalways)ÚcpuinfoT)Úrecord)z!-W ignore:Not importing directoryz"-W ignore:numpy.dtype size changedz"-W ignore:numpy.ufunc size changedz-W ignore::UserWarning:cpuinfoz$-W ignore:the matrix subclass is notz(-W ignore:Importing from numpy.matlib isz--doctest-modulesrú-Úvz--cov=r)ÚIS_PYPYz-mznot slow and not slow_pypyznot slowÚfullz--durations=%sz--pyargs)ÚpytestÚwarningsÚsysÚmodulesrÚosÚpathÚabspathÚ__path__Úcatch_warningsÚ simplefilterÚnumpy.distutilsr!Únumpy.array_apiÚlistÚ numpy.testingr%rÚmainÚ SystemExitÚcode)rÚlabelÚverboseÚ extra_argvÚdoctestsÚcoverageÚ durationsÚtestsr'r(ÚmoduleÚ module_pathÚ pytest_argsr!r r%r7Úexcs rÚ__call__zPytestTester.__call__Os€ð^ ˆ ˆ ˆ ؈ˆˆå”˜TÔ-Ô.ˆÝ”g—o’o f¤o°aÔ&8Ñ9Ô9ˆ ð�fˆ ð ˜�vш à × $Ò $Ñ &Ô &ð 0ð 0Ø × !Ò ! (Ñ +Ô +Ð +ð 0Ð /Ð /Ð /Ð /Ð /ð  0ð 0ð 0ñ 0ô 0ð 0ð 0ð 0ð 0ð 0ð 0øøøð 0ð 0ð 0ð 0ð× $Ò $¨DÐ $Ñ 1Ô 1ð #ð #ð #Ð "Ð "Ð "ð  #ð #ð #ñ #ô #ð #ð #ð #ð #ð #ð #øøøð #ð #ð #ð #ð ðððñ ˆ ð Ø 2Ø 6ðñ ˆ ð ð 1Ø Ð/Ð0Ñ 0ˆKà ð ,Ø �4  Ñ+Ô+Ñ +ˆKà �QŠ;ˆ;Ø ˜C # w°¡{Ñ"3Ñ3Ð4Ñ 4ˆKà ð 4Ø ˜H {Ñ2Ð3Ñ 3ˆKà �FŠ?ˆ?à -Ð -Ð -Ð -Ð -Ð -Øð 2Ø Ð&BÐCÑC� � à  jÐ1Ñ1� � à �fŠ_ˆ_Ø ˜D %˜=Ñ (ˆKà ˜Š>ˆ>Ø Ð,¨yÑ8Ð9Ñ 9ˆKà ˆ=ØÔ%Ð&ˆEà˜ �|¥d¨5¡k¤kÑ1Ñ1ˆ õ ÑÔÐð Ø—;’;˜{Ñ+Ô+ˆDˆDøÝð ð ð Ø”8ˆDˆDˆDˆDˆDˆDøøøøð øøøð�qŠyÐs<Á'BÂBÂBÂ0CÃCÃCÅ?FÆ F0ÆF+Æ+F0)rrNFFrN)Ú__name__Ú __module__Ú __qualname__Ú__doc__rrC©rrrr.sP€€€€€ððð:'ð'ð'ð<@ØEIððððððr)rGr)r+Ú__all__rrrHrrúrJsyðððð: € € € Ø € € € à Ð €ðIðIðIð`ð`ð`ð`ð`ñ`ô`ð`ð`ð`r