B <ÓFdxã@sddlmZmZmZddlZddlmZddlmZm Z m Z m Z m Z ddl mZddlmmZejddkr~ddlmZn ddlmZe  ejjdk¡d d „ƒZed d „ƒZed ddd„ƒZdd„ZeedddZdd„Zdd„Zdd„Zdd„Z dd„Z!dd „Z"e#d!kreƒdS)"é)ÚdivisionÚabsolute_importÚprint_functionN)Úarange)Úrun_module_suiteÚassert_Ú assert_equalÚassert_raises_regexÚdec)Ú deprecateé)ÚStringIOécCs0tƒ}tjdd|dd| ¡}td|kƒdS)NZ eigenvalueZnumpyF)ÚmoduleÚoutputZimport_modulesznumpy.linalg.eig)r ÚutilsZlookforÚgetvaluer)Úout©rúM/opt/alt/python37/lib64/python3.7/site-packages/numpy/lib/tests/test_utils.pyÚ test_lookfors  rcCs|S)Nr)ÚselfÚxrrrÚold_funcsrzRather use new_func2)ÚmessagecCs|S)Nr)rrrrrÚ old_func2srcCs|S)Nr)rrrrrÚ old_func3$srÚ new_func3)Zold_nameÚnew_namecCstdtjkƒdS)NZ deprecated)rrÚ__doc__rrrrÚtest_deprecate_decorator)sr cCstdtjkƒdS)NzRather use new_func2)rrrrrrrÚ test_deprecate_decorator_message-sr!cCs tdtjkƒtdtjkƒdS)Nrr)rrrrrrrÚtest_deprecate_fn1sr"cCst d¡dS)NÚNone)rZ safe_evalrrrrÚtest_safe_eval_nameconstant6sr$cCs8tdƒ dd¡}t |¡\}}t|||j|jƒdS)Né r é)rZreshaperZ byte_boundsrÚsizeÚitemsize)ÚaZlowZhighrrrÚtest_byte_bounds;sr*c Cs"ttdƒtdƒ‚WdQRXdS)Nzno deprecation warning)r Ú ValueErrorrrrrÚ(test_assert_raises_regex_context_managerAs r,Ú__main__)$Z __future__rrrÚsysZ numpy.corerZ numpy.testingrrrr r Z numpy.libr Znumpy.lib.utilsÚlibrÚ version_infoÚior ZskipifÚflagsÚoptimizerrrrrr r!r"r$r*r,Ú__name__rrrrÚs*