[ Avaa Bypassed ]




Upload:

Command:

hmhc3928@3.15.231.121: ~ $
U

'�7`+�@s�ddlZddlZddlZddlmZddlZddlmZmZddl	m
Z
ddlmZm
Z
mZmZmZmZmZmZzddlZWnek
r�dZYnXzddlZWnek
r�dZYnXdd�Zd	d
�Zejdd��Zejd
d��Zejdd��Zejd.dd��Zdd�Z dd�Z!dd�Z"ejdd��Z#ejdd��Z$ejdd��Zejd d!��Z%ejd"d#��Z&ejd$d%��Z'ejd&d'��Z(ejd(d)��Z)ejd*d+��Z*ejd,d-��Z+dS)/�N)�Callable)�PY_37�isasyncgenfunction)�Application�)�BaseTestServer�
RawTestServer�
TestClient�
TestServer�loop_context�setup_test_loop�teardown_test_loop�unused_portcCs:|jddddd�|jdddd	d�|jd
dddd�dS)N�--aiohttp-fast�
store_trueFz*run tests faster by disabling extra checks)�action�default�helpz--aiohttp-loopZstore�pyloopz:run tests with specific loop: pyloop, uvloop, tokio or all�--aiohttp-enable-loop-debugzenable event loop debug mode)Z	addoption)�parser�r�H/opt/alt/python38/lib64/python3.8/site-packages/aiohttp/pytest_plugin.py�pytest_addoption!s$���rcsb|j�t��rd�nt���r$d�ndSd�d|jkrH|jd7_d����fdd�}||_dS)zS
    Allow fixtures to be coroutines. Run coroutine fixtures in an event loop.
    TFN�request�rcsv|d}�r|d=d|jkr$td��|�d���rb�||����fdd�}|�|�������S���||��SdS)Nr�loopz^Asynchronous fixtures must depend on the 'loop' fixture or be used in tests depending from it.cs*z������WStk
r$YnXdS�N)�run_until_complete�	__anext__�StopAsyncIterationr��_loop�genrr�	finalizer`sz8pytest_fixture_setup.<locals>.wrapper.<locals>.finalizer)�fixturenames�	ExceptionZgetfixturevalueZaddfinalizerrr)�args�kwargsrr$��funcZis_async_genZ
strip_requestr!r�wrapperKs
�


z%pytest_fixture_setup.<locals>.wrapper)r*r�asyncio�iscoroutinefunction�argnames)Z
fixturedefr+rr)r�pytest_fixture_setup6s

 r/cCs|j�d�S)z--fast config optionr��config�	getoptionrrrr�fastnsr3cCs|j�d�S)z!--enable-loop-debug config optionrr0rrrr�
loop_debugtsr4c	cs`tjdd��J}dVdd�|D�}|rRtd�t|�t|�dkrBdnd	d
�|����W5QRXdS)z�
    Context manager which checks for RuntimeWarnings, specifically to
    avoid "coroutine 'X' was never awaited" warnings being missed.

    If RuntimeWarnings occur in the context a RuntimeError is raised.
    T)�recordNcSs"g|]}|jtkrdj|d��qS)z#{w.filename}:{w.lineno}:{w.message})�w)�category�RuntimeWarning�format)�.0r6rrr�
<listcomp>�s
�z,_runtime_warning_context.<locals>.<listcomp>z{} Runtime Warning{},
{}r��s�
)�warnings�catch_warnings�RuntimeErrorr9�len�join)�	_warningsZrwrrr�_runtime_warning_contextzs���rEFccs(|r|Vnt�}|Vt||d�dS)z{
    setups and tears down a loop unless one is passed in via the loop
    argument when it's passed straight through.
    �r3N)rr
)rr3rrr�_passthrough_loop_context�s
rGcCs(|�|�r$t�|�r$t|�||��SdS)z/
    Fix pytest collecting for coroutines.
    N)Zfuncnamefilterr,r-�listZ
_genfunctions)Z	collector�name�objrrr�pytest_pycollect_makeitem�srKc
s��j�d�}t��j�r��j�d�p0�j�dd�}t��Ft||d��.}�fdd��j	j
D�}|��jf|��W5QRXW5QRXdSdS)	zL
    Run coroutines in an event loop instead of a normal function call.
    r�
proactor_looprNrFcsi|]}|�j|�qSr)�funcargs)r:�arg��
pyfuncitemrr�
<dictcomp>�s�z&pytest_pyfunc_call.<locals>.<dictcomp>T)
r1r2r,r-ZfunctionrM�getrErGZ_fixtureinfor.rrJ)rPr3Z
existing_loopr"ZtestargsrrOr�pytest_pyfunc_call�s��
�&rScCs�d|jkrdS|jjj}dtji}tdk	r4tj|d<tdk	rFtj|d<|dkrRd}i}|�	d�D]N}|�
d�}|�d	�}||kr�|r`td
|t
|���f��nq`||||<q`|jdt
|���t
|���d�dS)N�loop_factoryr�uvloop�tokio�allzpyloop,uvloop?,tokio?�,�?z ?z&Unknown loop '%s', available loops: %s)Zids)r%r1ZoptionZaiohttp_loopr,ZDefaultEventLoopPolicyrUZEventLoopPolicyrV�split�endswith�strip�
ValueErrorrH�keysZparametrize�values)ZmetafuncZloopsZavail_factoriesZ	factoriesrIZrequiredrrr�pytest_generate_tests�s8





��

�r`c	csH|�}t�|�t|d��$}|r*|�d�t�|�|VW5QRXdS)z%Return an instance of the event loop.rFTN)r,�set_event_loop_policyrZ	set_debug�set_event_loop)rTr3r4�policyr"rrrr�s


rc	csRtst��}tj|_nt��}t�|�t|j��}t�	|�|VW5QRXdSr)
rr,Zget_event_loop_policyZProactorEventLoopZ
_loop_factoryZWindowsProactorEventLoopPolicyrarZnew_event_looprb)rcr"rrrrL�s


rLcCstjdtdd�|S)Nz3Deprecated, use aiohttp_unused_port fixture instead���
stacklevel�r?�warn�DeprecationWarning)�aiohttp_unused_portrrrr�s�rcCstS)z1Return a port that is unused on the current host.)�_unused_portrrrrrjsrjc#s:g�dd���fdd�
}|V�fdd�}��|��dS)z^Factory to create a TestServer instance, given an app.

    aiohttp_server(app, **kwargs)
    N��portc�s4t||d�}|jfd�i|��IdH��|�|S�Nrlr)r
�start_server�append)Zapprmr(�server�r�serversrr�gos
zaiohttp_server.<locals>.goc�s�r�����IdHqdSr��pop�closer�rsrr�finalizesz aiohttp_server.<locals>.finalize�r�rrtryrrrr�aiohttp_server	s
r|cCstjdtdd�|S)Nz.Deprecated, use aiohttp_server fixture insteadrdrerg)r|rrr�test_server s�r}c#s:g�dd���fdd�
}|V�fdd�}��|��dS)zpFactory to create a RawTestServer instance, given a web handler.

    aiohttp_raw_server(handler, **kwargs)
    Nrlc�s4t||d�}|jfd�i|��IdH��|�|Srn)rrorp)Zhandlerrmr(rqrrrrrt2s
zaiohttp_raw_server.<locals>.goc�s�r�����IdHqdSrrurrxrrry:sz$aiohttp_raw_server.<locals>.finalizerzr{rrrr�aiohttp_raw_server*s
r~cCstjdtdd�|S)Nz2Deprecated, use aiohttp_raw_server fixture insteadrdrerg)r~rrr�raw_test_serverAs�rc#s:g�dd���fdd�
}|V�fdd�}��|��dS)z�Factory to create a TestClient instance.

    aiohttp_client(app, **kwargs)
    aiohttp_client(server, **kwargs)
    aiohttp_client(raw_server, **kwargs)
    N)�
server_kwargsc�s�t|t�r.t|ttf�s.|�f|�|�}i}n|r:td��t|t�rv|pJi}t|fd�i|��}t|fd�i|��}n0t|t�r�t|fd�i|��}ntdt|���|�	�IdH��
|�|S)Nzargs should be emptyrzUnknown argument type: %r)�
isinstancerrr�AssertionErrorr
r	r]�typerorp)Z__paramr�r'r(rqZclient��clientsrrrrtUs"�


zaiohttp_client.<locals>.goc�s�r�����IdHqdSrrur)r�rrrynsz aiohttp_client.<locals>.finalizerzr{rr�r�aiohttp_clientKs
r�cCstjdtdd�|S)Nz.Deprecated, use aiohttp_client fixture insteadrdrerg)r�rrr�test_clientus�r�)F),r,�
contextlibr?Zcollections.abcrZpytestZaiohttp.helpersrrZaiohttp.webrZ
test_utilsrrr	r
rrr
rrkrU�ImportErrorrVrr/Zfixturer3r4�contextmanagerrErGrKrSr`rrLrjr|r}r~rr�r�rrrr�<module>s`(

8


"



	


	

	
)

Filemanager

Name Type Size Permission Actions
__init__.cpython-38.opt-1.pyc File 3.61 KB 0644
__init__.cpython-38.pyc File 3.61 KB 0644
abc.cpython-38.opt-1.pyc File 8.11 KB 0644
abc.cpython-38.pyc File 8.11 KB 0644
base_protocol.cpython-38.opt-1.pyc File 2.49 KB 0644
base_protocol.cpython-38.pyc File 2.58 KB 0644
client.cpython-38.opt-1.pyc File 27.85 KB 0644
client.cpython-38.pyc File 28 KB 0644
client_exceptions.cpython-38.opt-1.pyc File 10.03 KB 0644
client_exceptions.cpython-38.pyc File 10.03 KB 0644
client_proto.cpython-38.opt-1.pyc File 5.99 KB 0644
client_proto.cpython-38.pyc File 5.99 KB 0644
client_reqrep.cpython-38.opt-1.pyc File 26.76 KB 0644
client_reqrep.cpython-38.pyc File 27.02 KB 0644
client_ws.cpython-38.opt-1.pyc File 8.65 KB 0644
client_ws.cpython-38.pyc File 8.65 KB 0644
connector.cpython-38.opt-1.pyc File 30.14 KB 0644
connector.cpython-38.pyc File 30.27 KB 0644
cookiejar.cpython-38.opt-1.pyc File 9.07 KB 0644
cookiejar.cpython-38.pyc File 9.11 KB 0644
formdata.cpython-38.opt-1.pyc File 4.38 KB 0644
formdata.cpython-38.pyc File 4.41 KB 0644
frozenlist.cpython-38.opt-1.pyc File 2.56 KB 0644
frozenlist.cpython-38.pyc File 2.56 KB 0644
hdrs.cpython-38.opt-1.pyc File 3.53 KB 0644
hdrs.cpython-38.pyc File 3.53 KB 0644
helpers.cpython-38.opt-1.pyc File 22.43 KB 0644
helpers.cpython-38.pyc File 22.43 KB 0644
http.cpython-38.opt-1.pyc File 1.21 KB 0644
http.cpython-38.pyc File 1.21 KB 0644
http_exceptions.cpython-38.opt-1.pyc File 4.17 KB 0644
http_exceptions.cpython-38.pyc File 4.17 KB 0644
http_parser.cpython-38.opt-1.pyc File 15.58 KB 0644
http_parser.cpython-38.pyc File 15.66 KB 0644
http_websocket.cpython-38.opt-1.pyc File 14.34 KB 0644
http_websocket.cpython-38.pyc File 14.46 KB 0644
http_writer.cpython-38.opt-1.pyc File 4.88 KB 0644
http_writer.cpython-38.pyc File 4.88 KB 0644
locks.cpython-38.opt-1.pyc File 1.65 KB 0644
locks.cpython-38.pyc File 1.65 KB 0644
log.cpython-38.opt-1.pyc File 438 B 0644
log.cpython-38.pyc File 438 B 0644
multipart.cpython-38.opt-1.pyc File 25.11 KB 0644
multipart.cpython-38.pyc File 25.55 KB 0644
payload.cpython-38.opt-1.pyc File 12.8 KB 0644
payload.cpython-38.pyc File 12.8 KB 0644
payload_streamer.cpython-38.opt-1.pyc File 3.15 KB 0644
payload_streamer.cpython-38.pyc File 3.15 KB 0644
pytest_plugin.cpython-38.opt-1.pyc File 9.17 KB 0644
pytest_plugin.cpython-38.pyc File 9.22 KB 0644
resolver.cpython-38.opt-1.pyc File 3.7 KB 0644
resolver.cpython-38.pyc File 3.7 KB 0644
signals.cpython-38.opt-1.pyc File 1.26 KB 0644
signals.cpython-38.pyc File 1.26 KB 0644
streams.cpython-38.opt-1.pyc File 17.57 KB 0644
streams.cpython-38.pyc File 17.84 KB 0644
tcp_helpers.cpython-38.opt-1.pyc File 1.08 KB 0644
tcp_helpers.cpython-38.pyc File 1.08 KB 0644
test_utils.cpython-38.opt-1.pyc File 20.44 KB 0644
test_utils.cpython-38.pyc File 20.58 KB 0644
tracing.cpython-38.opt-1.pyc File 13.98 KB 0644
tracing.cpython-38.pyc File 13.98 KB 0644
typedefs.cpython-38.opt-1.pyc File 1.28 KB 0644
typedefs.cpython-38.pyc File 1.28 KB 0644
web.cpython-38.opt-1.pyc File 9.48 KB 0644
web.cpython-38.pyc File 9.48 KB 0644
web_app.cpython-38.opt-1.pyc File 14.85 KB 0644
web_app.cpython-38.pyc File 14.89 KB 0644
web_exceptions.cpython-38.opt-1.pyc File 11.73 KB 0644
web_exceptions.cpython-38.pyc File 11.73 KB 0644
web_fileresponse.cpython-38.opt-1.pyc File 4.47 KB 0644
web_fileresponse.cpython-38.pyc File 4.51 KB 0644
web_log.cpython-38.opt-1.pyc File 6.96 KB 0644
web_log.cpython-38.pyc File 6.96 KB 0644
web_middlewares.cpython-38.opt-1.pyc File 3.72 KB 0644
web_middlewares.cpython-38.pyc File 3.8 KB 0644
web_protocol.cpython-38.opt-1.pyc File 15.28 KB 0644
web_protocol.cpython-38.pyc File 15.46 KB 0644
web_request.cpython-38.opt-1.pyc File 22.07 KB 0644
web_request.cpython-38.pyc File 22.18 KB 0644
web_response.cpython-38.opt-1.pyc File 18.96 KB 0644
web_response.cpython-38.pyc File 19.87 KB 0644
web_routedef.cpython-38.opt-1.pyc File 7.62 KB 0644
web_routedef.cpython-38.pyc File 7.62 KB 0644
web_runner.cpython-38.opt-1.pyc File 11.35 KB 0644
web_runner.cpython-38.pyc File 11.45 KB 0644
web_server.cpython-38.opt-1.pyc File 2.69 KB 0644
web_server.cpython-38.pyc File 2.69 KB 0644
web_urldispatcher.cpython-38.opt-1.pyc File 40.38 KB 0644
web_urldispatcher.cpython-38.pyc File 41.2 KB 0644
web_ws.cpython-38.opt-1.pyc File 12.77 KB 0644
web_ws.cpython-38.pyc File 12.91 KB 0644
worker.cpython-38.opt-1.pyc File 6.7 KB 0644
worker.cpython-38.pyc File 6.77 KB 0644