403Webshell
Server IP : 121.121.20.254  /  Your IP : 216.73.217.51
Web Server : Microsoft-IIS/10.0
System : Windows NT WEB-SERVER 10.0 build 20348 (Windows Server 2022) AMD64
User : IUSR ( 0)
PHP Version : 8.3.28
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  C:/Python313/Lib/test/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : C:/Python313/Lib/test/__pycache__/test_decorators.cpython-313.pyc
�

��i>,����SSKrSSKJr Sr"SS\5r"SS\5rSSjrS	r	S
r
"SS\R5r"S
S\R5r
\S:Xa\R"5 gg)�N)�
MethodTypec�^�U4SjnU$)Nc�>>�URRT5 U$�N)�__dict__�update)�func�kwdss ��)C:\Python313\\Lib\test\test_decorators.py�decorate�funcattrs.<locals>.decorates����
�
���T�"����)r
rs` r�	funcattrsrs�����Orc�$�\rSrSr\S5rSrg)�MiscDecorators�
c�^�U4SjnU$)Nc�&>�TURS'U$)N�author)r)r	�names �rr�'MiscDecorators.author.<locals>.decorate
s���&*�D�M�M�(�#��Krr)rrs` rr�MiscDecorators.authors���	��rrN)�__name__�
__module__�__qualname__�__firstlineno__�staticmethodr�__static_attributes__rrrrr
s�����rrc��\rSrSrSrSrg)�DbcheckError�c�R�[RUSU<SU<SU<SU<S3	5 g)Nzdbcheck z failed (func=z args=z kwds=�))�	Exception�__init__)�self�exprstrr	�argsr
s     rr&�DbcheckError.__init__s �����4�#�T�4��"7�	8rrN)rrrrr&rrrrr!r!s��8rr!c�^^^�UUU4SjnU$)z+Decorator to implement debugging assertionsc�T>^^�[TSTR-S5mUUUUU4SjnU$)Nz
dbcheck-%s�evalc�R>�[TTT5(d
[TTX5eT"U0UD6$r)r-r!)r)r
�exprr(r	�globals�localss  �����r�check�(dbcheck.<locals>.decorate.<locals>.checks1�����g�v�.�.�"�7�D�$�=�=���&��&�&r)�compiler)r	r2r/r(r0r1s` @���rr�dbcheck.<locals>.decorates+����w��t�}�}� <�f�E��	'�	'��rr)r(r0r1rs``` r�dbcheckr6s�����Orc�^�U4SjnU$)z&Decorator to count calls to a functionc�L>^^�TRmSTT'UUU4SjnTUlU$)Nrc�.>�TT==S-
ss'T"U0UD6$)N�r)r)r
�countsr	�	func_names  ���r�call�*countcalls.<locals>.decorate.<locals>.call-s#����9���"����&��&�&r�r)r	r=r<r;s` @�rr�countcalls.<locals>.decorate*s)����M�M�	���y��	'�"��
��rr)r;rs` r�
countcallsrA(s�����Orc�>^^�0mUU4SjnTRUlU$)Nc�h>�TU$![a T"U6nUTU'Us$[a T"U6s$f=fr)�KeyError�	TypeError)r)�resr	�saveds  ��rr=�memoize.<locals>.call8sJ���	���;����	���+�C��E�$�K��J��	���;��	�s��1�1�1r?)r	r=rGs` @r�memoizerI6s����E�	��M�M�D�M��Krc�h�\rSrSrSrSrSrSrSrSr	Sr
S	rS
rSr
SrS
rSrSrSrg)�TestDecorators�Gc��"SS[5nURUR5S5 URU"5R5S5 g)Nc�$�\rSrSr\S5rSrg)�%TestDecorators.test_single.<locals>.C�Jc��g�N�*rrrr�foo�)TestDecorators.test_single.<locals>.C.fooKs�� rrN)rrrrrrTrrrr�CrOJs��
� �� rrVrS)�object�assertEqualrT�r'rVs  r�test_single�TestDecorators.test_singleIs>��	!��	!�	
�������"�%���������B�'rc�:�SnU"U5nURURU5 URURU5 SH'nUR[XE5[X555 M) UR	[U5UR
U55 U$)Nc��U$rr��xs rr	�0TestDecorators.check_wrapper_attrs.<locals>.funcQs���Hr)rrr�__doc__�__annotations__)�assertIs�__func__�__wrapped__�getattrrX�repr�format)r'�method_wrapper�
format_strr	�wrapper�attrs      r�check_wrapper_attrs�"TestDecorators.check_wrapper_attrsPs���	� ��&���
�
�g�&�&��-��
�
�g�)�)�4�0�3�D��M�M�'�'�0�!�$�-�
/�3�
	
����g��
�(9�(9�$�(?�@��rc�`�UR[S5nURU"S5S5 g)Nz<staticmethod({!r})>r:)rmrrX�r'rks  r�test_staticmethod� TestDecorators.test_staticmethod`s+���*�*�<�9O�P��	
������Q�'rc�^�UR[S5nUR[US5 g)Nz<classmethod({!r})>r:)rm�classmethod�assertRaisesrErps  r�test_classmethod�TestDecorators.test_classmethodfs'���*�*�;�8M�N�����)�W�a�0rc��[5nURS5S5nURU"5S5 URURS5 g)N�Cleesec��grRrrrrrT�'TestDecorators.test_dotted.<locals>.fooms��rrS)rrrX)r'�
decoratorsrTs   r�test_dotted�TestDecorators.test_dottedksI��#�%�
�	�	�	�8�	$��
%��������#�������X�.rc	��SnSn[SSS9nU"U0UD6S5nURU"5S5 URURX#45 U"SS	S
SS9S
5nURU"5S5 URURS[S
SS945 U"SS5S5nURURS045 g)Nc�^^�UU4SjnU$)Nc�&>�[USTT45 U$)N�dbval)�setattr)r	r)r
s ��rr�@TestDecorators.test_argforms.<locals>.noteargs.<locals>.decoratews�����g��d�|�4��rr)r)r
rs`` r�noteargs�.TestDecorators.test_argforms.<locals>.noteargsvs���
��Or)�Now�is�the�timer:�)�one�twoc��grRrrrr�f1�(TestDecorators.test_argforms.<locals>.f1~���rrS�terry�gilliam�idle�cleese)�eric�johnc��g)N�Trrrr�f2�(TestDecorators.test_argforms.<locals>.f2�r�rr�)r�r�c��grrrrr�f3�(TestDecorators.test_argforms.<locals>.f3�s��r)r:r�)�dictrXr�)r'r�r)r
r�r�r�s       r�
test_argforms�TestDecorators.test_argformsrs���	�.����q�!��	�4�	 �4�	 ��
!�������r�"�������D�<�0�	�'�9�6��	A��
B�������r�"�������$8�%)�v�H�%E�$G�	H�
�!�Q���
��������F�B�<�0rc��[S5S5nURU"SS5S5 UR[USS5 g)Nzargs[1] is not Nonec�
�X-$rr)�a�bs  r�f�&TestDecorators.test_dbcheck.<locals>.f�s	���5�Lrr:r��)r6rXrur!)r'r�s  r�test_dbcheck�TestDecorators.test_dbcheck�sD��	�&�	'�	�
(�	�����1�a��!�$����,��1�d�3rc�t�0n[[U5S55nURURS5 URU[	SS95 URU"S5S5 URUSS5 URU"S5S5 URUSS5 URU"S5S	5 URUSS5 URU"S
/5S
S
/5 URUSS5 URU"S
/5S
S
/5 URUSS5 g)Nc��US-$)Nr�rr^s r�double�+TestDecorators.test_memoize.<locals>.double�s
���q�5�Lrr�r)r�r��r:r��r)rIrArXrr�)r'r;r�s   r�test_memoize�TestDecorators.test_memoize�s+����	�	�F�	�	�
�
�	�������(�3������Q��0�	
������A�&������)�1�-�������A�&������)�1�-�������A�&������)�1�-�	
��������B�x�0������)�1�-���������B�x�0������)�1�-rc��SH?n[USS5 UR[5 [SUS3SS5 SSS5 MA SH=n[USS5 UR[5 [	SUS35 SSS5 M? Sn[SUS	9nS
[4S[4S[4S
[44H.up%SU-n[USS5nURU[Xt5 M0 g!,(df   M�=f!,(df   M�=f)N)zx,zx, yzx = y�passz
import sys�test�exec�@�
def f(): pass)z1.+2jz
[1, 2][-1]z(1, 2)�Truez...�Noner-c��[er)�NotImplementedError)r	s r�unimp�)TestDecorators.test_errors.<locals>.unimp�s��%�%r)�nullvalr��undefr�znullval.attrr�z$@%s
def f(): pass
assert f() is None)
r4ru�SyntaxErrorrEr�r��	NameError�AttributeErrorr�r-)r'�stmtr/r��context�exc�codestr�codes        r�test_errors�TestDecorators.test_errors�s��B�D��D�&�&�)��"�"�;�/��!�D�6��1�6�6�B�0�/�B�M�D��D�&�&�)��"�"�9�-��q���o�.�/�.�-�M�
	&��t�5�1��#�Y�/�%�y�1�*�N�;�#�%8�9�;�I�D�?��E�G��7�F�F�3�D����c�4��7�
;�0�/��.�-�s�C'�-C9�'
C6	�9
D	c�8�SHn[SUS3SS5 M g)N)z(x,)z(x, y)zx := yz(x := y)zx @yz(x @ y)zx[0]zw[x].y.zzw + x - (y + z)z	x(y)()(z)z[w, x, y][z]zx.yr�r�r�r�)r4)r'r/s  r�test_expressions�TestDecorators.test_expressions�s%��
�D�
�a��v�_�-�v�v�>�	
rc�P�"SS[5nURU"5R5S5 URURRS5 URURRS5 URURR
S5 g)Nc�@�\rSrSr\"SSS9\"SS9S55rSrg	)
�%TestDecorators.test_double.<locals>.C��r:�haha)�abc�xyzrS)�boohc��grRr)r's rrT�)TestDecorators.test_double.<locals>.C.foo�s��"$rrN)rrrrrrTrrrrrVr��s$��
�1�&�
)�
�B�
�$� �*�$rrVrSr:r�)rWrXrTr�r�r�rYs  r�test_double�TestDecorators.test_double�sp��	%��	%�	
��������B�'���������A�&���������F�+���������R�(rc�l�SnU"S5U"S5S55nURU"5SS5 g)Nc�^�U4SjnU$)zxDecorator factory that returns a decorator that replaces the
passed-in function with one that returns the value of 'num'c�>�U4Sj$)Nc�>�T$rr)�nums�r�<lambda>�JTestDecorators.test_order.<locals>.callnum.<locals>.deco.<locals>.<lambda>�s���srr)r	r�s �r�deco�8TestDecorators.test_order.<locals>.callnum.<locals>.deco�s	���"�"rr)r�r�s` r�callnum�*TestDecorators.test_order.<locals>.callnum�s
���
#��Krr�r:c��grRrrrrrT�&TestDecorators.test_order.<locals>.foo�s��rz,Application order of decorators is incorrect)rX)r'r�rTs   r�
test_order�TestDecorators.test_order�s?��	�
���	����
�
��������J�	Lrc�^^	�/mU4Sjm	"UU	4SjS[5n[U/SQ5up#n/SQn/mURUR5URUR5URUR5S555nUR	U"5S5 UR	TU5 /mSnURUR5"URUR5"URUR5"U555nUR	U"5S5 UR	TU5 g)	Nc�@>^�TRST-5 UU4SjnU$)N�makedecc�0>�TRST-5 U$)N�calldec��append)r	�actions�tags ��rr�HTestDecorators.test_eval_order.<locals>.make_decorator.<locals>.decorate�s������y�3��/��rr�)r�rr�s` �r�make_decorator�6TestDecorators.test_eval_order.<locals>.make_decorator�s����N�N�9�s�?�+�
��Orc�*>�\rSrSrSrUU4SjrSrg)�8TestDecorators.test_eval_order.<locals>.NameLookupTracer�c��Xlgr��index)r'r�s  rr&�ATestDecorators.test_eval_order.<locals>.NameLookupTracer.__init__s��"�
rc�>�US:XaSTp2O'US:XaS[UR5p2O
SU-5eTRSX R4-5 U$)Nr��evalname�arg�evalargszUnknown attrname %sz%s%d)�strr�r�)r'�fname�opnamerFr�r�s    ��r�__getattr__�DTestDecorators.test_eval_order.<locals>.NameLookupTracer.__getattr__sV����,�,�#-�~�C��e�^�#-�s�4�:�:��C�?�"7�%�"?�?�5����v����(<�<�=��
rr�N)rrrrr&rr)r�r�s��r�NameLookupTracerr�s���
#�
�
rr)r:r�r�)�	evalname1�	evalargs1�makedec1�	evalname2�	evalargs2�makedec2�	evalname3�	evalargs3�makedec3�calldec3�calldec2�calldec1c��grRrrrrrT�+TestDecorators.test_eval_order.<locals>.foos��rrSc��grRrrrr�bar�+TestDecorators.test_eval_order.<locals>.bar!s��"r)rW�mapr�r�rX)
r'r�c1�c2�c3�expected_actionsrTrr�r�s
        @@r�test_eval_order�TestDecorators.test_eval_order�s%�����	�	�	��	��)�;�7�
���B��
��	�	�	�2�6�6�	"�	�	�	�2�6�6�	"�	�	�	�2�6�6�	"��
#�
#�
#�	�������#�����"2�3����������'��(9�(9�"�&�&�(A�"�BS�BS�TV�TZ�TZ�B[�\_�B`�(a�b��������#�����"2�3rc�t^�"SS5m"U4SjS5nURUR5S5 g)Nc��\rSrSrSrSrg)�@TestDecorators.test_bound_function_inside_classmethod.<locals>.Ai'c��g)N�spamr)r'�clss  rrT�DTestDecorators.test_bound_function_inside_classmethod.<locals>.A.foo(s��rrN)rrrrrTrrrr�Ar 's��
rr%c�F>�\rSrSr\"Y"5R
5rSrg)�@TestDecorators.test_bound_function_inside_classmethod.<locals>.Bi+rN)rrrrrtrTrr)r%s�r�Br'+s����a�c�g�g�&�Crr(r")rXr)r'r(r%s  @r�&test_bound_function_inside_classmethod�5TestDecorators.test_bound_function_inside_classmethod&s/���	�	�	'�	'�	
�������&�)rrN)rrrrrZrmrqrvr}r�r�r�r�r�r�r�rr)rrrrrKrKGsJ��(�� (�1�
/�1�64�.�68�4?�)�
L�;4�z*rrKc�&�\rSrSrSrSrSrSrg)�TestClassDecoratorsi1c�j�SnU"SS[55nURURS5 g)Nc��SUlU$)N�Hello��extrar^s r�plain�.TestClassDecorators.test_simple.<locals>.plain4����A�G��Hrc��\rSrSrSrg)�*TestClassDecorators.test_simple.<locals>.Ci7rN�rrrrrrrrrVr67s��rrVr/�rWrXr1)r'r2rVs   r�test_simple�TestClassDecorators.test_simple3s0��	�
����
��������'�*rc�z�SnSnUU"SS[555nURURS5 g)Nc��SUlU$)Nrr0r^s r�ten�,TestClassDecorators.test_double.<locals>.ten<s���A�G��Hrc�0�U=RS-
slU$)N�r0r^s r�add_five�1TestClassDecorators.test_double.<locals>.add_five?s��
�G�G�q�L�G��Hrc��\rSrSrSrg)�*TestClassDecorators.test_double.<locals>.CiCrNr7rrrrVrDC���rrV�r8)r'r=rArVs    rr��TestClassDecorators.test_double;s=��	�	�
�	����

�
��������"�%rc�z�SnSnUU"SS[555nURURS5 g)Nc��SUlU$)N�firstr0r^s r�
applied_first�5TestClassDecorators.test_order.<locals>.applied_firstIr4rc��SUlU$)N�secondr0r^s r�applied_second�6TestClassDecorators.test_order.<locals>.applied_secondLs���A�G��Hrc��\rSrSrSrg)�)TestClassDecorators.test_order.<locals>.CiOrNr7rrrrVrROrErrVrNr8)r'rKrOrVs    rr��TestClassDecorators.test_orderHs=��	�	�
�	����
�
��������(�+rrN)rrrrr9r�r�rrrrr,r,1s��+�&�
,rr,�__main__)NN)�unittest�typesrrrWrr%r!r6rArI�TestCaserKr,r�mainrrr�<module>rYsw������f��8�I�8�	�
�
�"g*�X�&�&�g*�T!,�(�+�+�!,�F�z���M�M�O�r

Youez - 2016 - github.com/yon3zu
LinuXploit