ok
Direktori : /opt/alt/python36/lib64/python3.6/test/support/__pycache__/ |
Current File : //opt/alt/python36/lib64/python3.6/test/support/__pycache__/__init__.cpython-36.pyc |
3 'j�a� � � @ s� d Z edkred��ddlZddlZddlZddlZddlZddl Z ddl Z ddlZddlZddl ZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddl Z!ddl"Z"ddl#m$Z$ yddl%Z%ddl&Z&W n ek �r: dZ%dZ&Y nX yddl'Z(W n ek �rb dZ(Y nX yddl)Z)W n ek �r� dZ)Y nX yddl*Z*W n ek �r� dZ*Y nX yddl+Z+W n ek �r� dZ+Y nX yddl,Z,W n ek �r dZ,Y nX yddl-Z-W n ek �r* dZ-Y nX ddd d ddd ddddddddddddddddddd d!d"d#d$d%d&d'd(d)d*d+d,d-d.d/d0d1d2d3d4d5d6d7d8d9d:d;d<d=d>d?d@dAdBdCdDdEdFdGdHdIdJdKdLdMdNdOdPdQdRdSdTdUdVdWdXdYdZd[d\d]d^d_d`dag[Z.G dbd� de/�Z0G dcd � d e0�Z1G ddd� de0�Z2G ded� dej3�Z4ej5�d]dgdh��Z6�d^f dj�dkd�Z7dldm� Z8dndo� Z9dpd<� Z:dqd=� Z;f f difdrd�Z<dsd8� Z=dZ>dZ?da@daAdZBdiZCdaDdtd� ZEdud� ZFdvd� ZGdwdx� ZHejjIdy��r��d_dzd{�ZJd|d}� ZKd~d� ZLd�d�� ZMd�d�� ZNnejOZKejPZLd�d�� ZMd�d�� ZNd�d� ZOd�d�� ZPd�d� ZQd�d�� ZRd�d� ZSd�d�� ZTd�d#� ZU�d`d�d$�ZVd�d�� ZWd�d%� ZXd�d&� ZYd�d'� ZZd�Z[d�Z\ej]ej^fd�dI�Z_e[fd�dJ�Z`d�dL� Zad�d�� Zbeb� Zcd�d�� Zd�dcZe�dfZfejgehjid��jId��d��Zjejge)d��Zkejge*d��Zlejge+d��Zmejge,d��ZnejjId��Zoejpd��Zqeqdk �o:eqdkZrejd�k�rXer�rRd�nd�ZsndZsejtd�k�rnd�Zund�Zud�jveuejw� �ZudZxxL�dgD ]BZyyejzej{ey��eyk�r�e|�W n e|k �r� Y nX eyZxP �q�W eud� Z}ejd�k�r�ddl~Z~e~jd�e}�Z}ej�� Z�dZ�ejtd�k�rhej�� jd�k�r�eud� Z�ye�j�e�� W n e�k �rP Y nX e�d�e�e�f � dZ�nBejd�k�r�yd�j�e�� W n& e�k �r� eud�j�e�dŃ Z�Y nX dZ�xF�dhD ]<Ztyetj�e�� W n& e�k �r� ej{eu�et Z�P Y nX �q�W ex�r eud� ex Z�ndZ�ej�� Z�diZ�ej5�did�d̄�Z�ej5�djd�d΄�Z�ej5�dkd�d��Z�e�edу�rjej5d�dM� �Z�ej�j�ej�j�e���Z�ej�j�e��Z�ej�j�e�dӃZ��dld�d�Z�d�d � Z�d�d]� Z�d�d Z�dddٜd�d(�Z�d�dK� Z�G d�d݄ d�e��Z��dmd�d߄Z�ej5d�dT� �Z�ej5d�dU� �Z�G d�d� de��Z�G d�dV� dVej�j��Z�G d�d� d�e��Z�G d�d)� d)e��Z�e�e�ej�d�Z�e�e�ej�d�Z�e�e�ej�d�Z�ej5d�f d�d�d-��Z�ej5d�d� �Z�d�d� Z�d�d� Z�d�d� Z�d�d� Z�ej5d�d� �Z�d�d�� Z�d�Z�d�Z�e�ed���r�d�e� Z�d�Z�e�d� Z�d�d�� Z�d�d�� Z��dnZ��doZ��d�d� Z��ddW� Zdd^� ZÐdpZ�d�e� Z�d�e� Z�d�e� Z�ej�Zɐdd[� Z�G �d�d� �d�Zːdq�d d5�Z̐d d6� Z�G �dd.� d.�Zΐd�d � Zϐd�d� ZАdd@� Zѐdd7� ZҐdr�d�d�Z�daԐddA� ZՐd�d� ZddD� Zאd�d� Zؐd�d� Zِd�d� Zڐd�d� Z�da�daݐd �d!� Zސd"�d#� Zߐd$�d%� Z�d&d/� Z�d'�d(� Z�e׃ � o�ejd�k� o�ejp�d)� Z�e�j dk � o�e� Z�ejge�d*�Z�ds�d+d0�Z�d,�d-� Z�d.�d/� Z�diZ�d0dP� Z�d1dQ� Z�d2dR� Z�ej5�dt�d4�d5��Z�d6dN� Z�ej5�du�d7dS��Z�ej5�d8dY� �Z�ej5�d9dX� �Z�d:�d;� Z�ej�e�e�d<��d=�Z�d>�d?� Z��d@�dA� Z�G �dBdO� dOej�j��Z�G �dCdZ� dZe��Z�da��dDd!� Z��dEd1� Z�da��dF�dG� Z��dHd:� �Z �dId"� �Zf �dJ��dKd>��Zdf f f�dLd?��ZG �dMd\� d\��Z�dN�dO� �Z�dP�dQ� �Zf f�dR�dS��Zg f�dTd`��Zd�a �dUdF� �Z ej5�dV�dW� ��Z�dXda� �ZG �dY�dZ� �dZ��Z G �d[�d\� �d\��ZdS (v z7Supporting definitions for the Python regression tests.ztest.supportz.support must be imported from the test package� N� )�get_test_runner� PIPE_MAX_SIZE�verbose� max_memuse� use_resources�failfast�Error� TestFailed� TestDidNotRun�ResourceDenied� import_module�import_fresh_module�CleanImport�unload�forget�record_original_stdout�get_original_stdout�captured_stdout�captured_stdin�captured_stderr�TESTFN�SAVEDCWD�unlink�rmtree�temp_cwd�findfile�create_empty_file�can_symlink�fs_is_case_insensitive�is_resource_enabled�requires�requires_freebsd_version�requires_linux_version�requires_mac_ver�check_syntax_error�TransientResource�time_out�socket_peer_reset�ioerror_peer_reset�transient_internet�BasicTestRunner�run_unittest�run_doctest�skip_unless_symlink� requires_gzip�requires_bz2� requires_lzma� bigmemtest�bigaddrspacetest�cpython_only� get_attribute�requires_IEEE_754�skip_unless_xattr� requires_zlib�anticipate_failure�load_package_tests�detect_api_mismatch�check__all__�requires_android_level�requires_multiprocessing_queue� is_jython� is_android�check_impl_detail� unix_shell�setswitchinterval�HOST�IPV6_ENABLED�find_unused_port� bind_port�open_urlresource�bind_unix_socket� temp_umask� reap_children�TestHandler�threading_setup�threading_cleanup�reap_threads� start_threads�check_warnings�check_no_resource_warning�EnvironmentVarGuard�run_with_locale� swap_item� swap_attr�Matcher�set_memlimit�SuppressCrashReport�sortdict�run_with_tz�PGO�missing_compiler_executable�fd_countc @ s e Zd ZdZdS )r z*Base class for regression test exceptions.N)�__name__� __module__�__qualname__�__doc__� rc rc �:/opt/alt/python36/lib64/python3.6/test/support/__init__.pyr u s c @ s e Zd ZdZdS )r zTest failed.N)r_ r` ra rb rc rc rc rd r x s c @ s e Zd ZdZdS )r zTest did not run any subtests.N)r_ r` ra rb rc rc rc rd r { s c @ s e Zd ZdZdS )r z�Test skipped because it requested a disallowed resource. This is raised when a test calls requires() for a resource that has not be enabled. It is used to distinguish between expected and unexpected skips. N)r_ r` ra rb rc rc rc rd r ~ s Tc c s8 | r.t j� � t jddt� dV W dQ R X ndV dS )z�Context manager to suppress package and module deprecation warnings when importing them. If ignore is False, this context manager has no effect. �ignorez.+ (module|package)N)�warnings�catch_warnings�filterwarnings�DeprecationWarning)re rc rc rd �_ignore_deprecated_imports� s rj F)�required_onc C sf t |��T y tj| �S tk rV } z&tjjt|��r8� tj t |���W Y dd}~X nX W dQ R X dS )ac Import and return the module to be tested, raising SkipTest if it is not available. If deprecated is True, any module or package deprecation messages will be suppressed. If a module is required on a platform but optional for others, set required_on to an iterable of platform prefixes which will be compared against sys.platform. N)rj � importlibr �ImportError�sys�platform� startswith�tuple�unittest�SkipTest�str)�name� deprecatedrk �msgrc rc rd r � s c C s^ | t jkrt| � t j| = x>tt j�D ]0}|| ks@|j| d �r&t j| ||<