%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib64/python3.9/site-packages/numpy/tests/__pycache__/
Upload File :
Create Path :
Current File : //lib64/python3.9/site-packages/numpy/tests/__pycache__/test_reloading.cpython-39.pyc

a

z[yc��@sdddlmZmZmZmZddlmZddlZddlZddl	Z	ddl
mZdd�Zdd�Z
d	d
�ZdS)�)�
assert_raises�assert_warns�assert_�assert_equal)�pickleN)�reloadcCs�ddl}ddl}|j}|j}|j}tt��t|�Wd�n1sH0Yt||ju�t||ju�t||ju�t	t
t|j�tt��t|�Wd�n1s�0Yt||ju�t||ju�t||ju�dS)Nr)�numpyZnumpy._globals�_NoValue�VisibleDeprecationWarning�ModuleDeprecationWarningr�UserWarningrrr�RuntimeErrorZ_globals)�nprr	r
r�r�@/usr/lib64/python3.9/site-packages/numpy/tests/test_reloading.py�test_numpy_reloading
s 
&
&rcCsRddl}tdtjd�D]4}tt|j�d�tt�tj	|j|d��|ju�qdS)Nr��z
<no value>)Zprotocol)
r�rangerZHIGHEST_PROTOCOLr�reprr	r�loads�dumps)r�protorrr�test_novalue s��rcCsFt�d�}tjtjd|gdd�}|jrBtd|j�d|j�	�����dS)z�At the time of writing this, it is *not* truly supported, but
    apparently enough users rely on it, for it to be an annoying change
    when it started failing previously.
    a
        import sys
        from pytest import warns
        import numpy as np

        for k in list(sys.modules.keys()):
            if "numpy" in k:
                del sys.modules[k]

        with warns(UserWarning):
            import numpy as np
        z-cT)Zcapture_outputzNon-zero return code: z

N)
�textwrap�dedent�
subprocess�run�sys�
executable�
returncode�AssertionError�stderr�decode)�code�prrr�test_full_reimport(s
�r&)Z
numpy.testingrrrrZnumpy.compatrrrr�	importlibrrrr&rrrr�<module>s

Zerion Mini Shell 1.0