$77 GRAYBYTE WORDPRESS FILE MANAGER $23

SERVER : premium201.web-hosting.com #1 SMP Wed Mar 26 12:08:09 UTC 2025
SERVER IP : 172.67.162.162 | ADMIN IP 216.73.216.174
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/opt/hc_python/lib/python3.12/site-packages/nose/tools/__pycache__/

HOME
Current File : /opt/hc_python/lib/python3.12/site-packages/nose/tools/__pycache__//nontrivial.cpython-312.pyc
�

H��gJ��Z�dZddlZgd�ZGd�de�Zd�Zd�Zd�Zd	�Zd
d
�Z	d�Z
d�Zy)z8Tools not exempt from being descended into in tracebacks�N)�make_decorator�raises�	set_trace�timed�
with_setup�TimeExpired�istest�nottestc��eZdZy)rN)�__name__�
__module__�__qualname__���D/opt/hc_python/lib/python3.12/site-packages/nose/tools/nontrivial.pyrr
s��rrc����fd�}|S)z�
    Wraps a test decorator so as to properly replicate metadata
    of the decorated function, including nose's additional stuff
    (namely, setup and teardown).
    c�D��t�d�r
�j}n�j}�j|_�j|_�j
|_t|d�s�jj|_	||_|S#t$r||_Y|SwxYw)N�compat_func_name�compat_co_firstlineno)
�hasattrrr�__dict__�__doc__r
�__code__�co_firstlinenor�	TypeError)�newfunc�name�funcs  �r�decoratez make_decorator.<locals>.decorates�����4�+�,��(�(�D��=�=�D��=�=����,�,���!�_�_����w� 7�8�,0�M�M�,H�,H�G�)�	,�#�G������	,�'+�G�$���	,�s�B�B�Br)rrs` rrrs���� �Orc�r���dj�D�cgc]}|j��c}����fd�}|Scc}w)a�Test must raise one of expected exceptions to pass.

    Example use::

      @raises(TypeError, ValueError)
      def test_raises_type_error():
          raise TypeError("This test passes")

      @raises(Exception)
      def test_that_fails_by_passing():
          pass

    If you want to test many assertions about exceptions in a single test,
    you may want to use `assert_raises` instead.
    z or c�V�����j�����fd�}t��|�}|S)Nc�R��	�|i|����d���}t|��#�$rYy�xYw)Nz() did not raise )�AssertionError)�arg�kw�message�
exceptionsrr�valids   ����rrz)raises.<locals>.decorate.<locals>.newfunc:sC���
.��c� �R� �6:�5�A��$�W�-�-��
�
��
��s��&�&)rr)rrrr'r(s` @��rrzraises.<locals>.decorate8s)����}�}��		.�'�.��&�w�/���r)�joinr)r'�err(s`  @rrr's7��� 
�K�K�Z�8�Z�����Z�8�9�E�
��O��9s�4c��ddl}ddl}|j}|j|_|j	�j|j
�j�y)z�Call pdb.set_trace in the calling frame, first restoring
    sys.stdout to the real output stream. Note that sys.stdout is NOT
    reset to whatever it was before the call once pdb is done!
    rN)�pdb�sys�stdout�
__stdout__�Pdbr�	_getframe�f_back)r,r-r.s   rrrIs>��
��
�Z�Z�F����C�J��G�G�I����
�
��.�.�/rc����fd�}|S)z�Test must finish within specified time limit to pass.

    Example use::

      @timed(.1)
      def test_that_fails():
          time.sleep(.2)
    c�8�����fd�}t��|�}|S)Nc���tj�}�|i|��}tj�}||z
�kDrtd�z��|S)NzTime limit (%s) exceeded)�timer)r$r%�start�result�endr�limits     ��rrz(timed.<locals>.decorate.<locals>.newfunc_sJ����I�I�K�E��3�%�"�%�F��)�)�+�C��U�{�U�"�!�"<�u�"D�E�E��Mr)r)rrr:s` �rrztimed.<locals>.decorate^s ���	�'�.��&�w�/���rr)r:rs` rrrUs���	��Orc��||fd�}|S)aDecorator to add setup and/or teardown methods to a test function::

      @with_setup(setup, teardown)
      def test_something():
          " ... "

    Note that `with_setup` is useful *only* for test functions, not for test
    methods or inside of TestCase subclasses.
    c��������r-t|d�r|j���fd�}||_n�|_�r.t|d�r|j���fd�}||_|S�|_|S)N�setupc�"������y�Nr)�_old_sr=s��r�_sz(with_setup.<locals>.decorate.<locals>._sys
����G��Hr�teardownc�"������yr?r)�_old_trBs��r�_tz(with_setup.<locals>.decorate.<locals>._t�s
����H��Jr)rr=rB)rr=rBrArEr@rDs ``  @@rrzwith_setup.<locals>.decorateusg�����t�W�%������ ��
�"��
���t�Z�(������!#��
���!)��
��rr)r=rBrs   rrrks��#�X��(�Orc��d|_|S)z5Decorator to mark a function or method as a test
    T��__test__�rs rr	r	�s���D�M��Krc��d|_|S)z;Decorator to mark a function or method as *not* a test
    FrGrIs rr
r
�s���D�M��Kr)NN)rr6�__all__r#rrrrrrr	r
rrr�<module>rLsC��>��/��	�.�	��2�D	0��,�B�r


Current_dir [ NOT WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
4 Apr 2025 8.03 AM
root / root
0755
__init__.cpython-312.pyc
0.549 KB
4 Apr 2025 8.03 AM
root / root
0644
nontrivial.cpython-312.pyc
5.873 KB
4 Apr 2025 8.03 AM
root / root
0644
trivial.cpython-312.pyc
2.159 KB
4 Apr 2025 8.03 AM
root / root
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025 CONTACT ME
Static GIF