%PDF- %PDF-
Direktori : /lib/python3/dist-packages/twisted/web/test/__pycache__/ |
Current File : //lib/python3/dist-packages/twisted/web/test/__pycache__/test_proxy.cpython-312.pyc |
� Ϫ�fLN � � � d Z ddlmZmZ ddlmZ ddlmZmZm Z m Z mZ ddlm Z ddlmZ ddlmZ G d� d e� Z G d � d� Z G d� d e� Z G d� de� Z G d� de� Z G d� d� Z G d� de� Zy)z Test for L{twisted.web.proxy}. � )� MemoryReactor� StringTransportWithDisconnection)�TestCase)�ProxyClient�ProxyClientFactory�ProxyRequest�ReverseProxyRequest�ReverseProxyResource)�Resource)�Site��DummyRequestc �4 � e Zd ZdZd� Zd� Zd� Zd� Zd� Zd� Z y) �ReverseProxyResourceTestsz, Tests for L{ReverseProxyResource}. c �R � t � }t � }t ddd|� }|j d|� t |� }t � }|j d� }|j |� | j |j d� |j d|z dz � |j \ \ } } }}} | j | d� | j | d� | j |t � | j |j |� | j |j d d � y) z� Check that a request pointing at C{uri} produce a new proxy connection, with the path of this request pointing at C{expectedURI}. � 127.0.0.1�� � /paths indexNs GET s HTTP/1.1 Accept: text/html � hosts 127.0.0.1:1234)r r r �putChildr r � buildProtocol�makeConnection� addCleanup�connectionLost�dataReceived� tcpClients�assertEqual�assertIsInstancer �rest�headers)�self�uri�expectedURI�root�reactor�resource�site� transport�channel�host�port�factory�_timeout� _bind_addrs �=/usr/lib/python3/dist-packages/twisted/web/test/test_proxy.py�_testRenderz%ReverseProxyResourceTests._testRender s � � �z���/��'��T�8�W�M��� � �h��)��D�z��4�6� ��$�$�T�*�����y�)�����.�.��5����W�s�]�-V�V�W�8?�8J�8J�5� 4�$��g�x������{�+�����t�$� ���g�'9�:�������{�3��������1�3D�E� c �&