U
    
W[m  ã                   @   sJ   d Z ddlmZmZ ddlZddlmZ ddlmZ G dd„ dej	ƒZ
dS )z|
The L{_response} module contains constants for all standard HTTP codes, along
with a mapping to the corresponding phrases.
é    )ÚdivisionÚabsolute_importN)Úunittest)Ú
_responsesc                   @   s   e Zd Zdd„ ZdS )ÚResponseTestsc                 C   sR   t tƒD ]D}|dkrqtdd„ |D ƒƒrtt|ƒ}|  |t¡ |  |tj¡ qdS )z
        All constants besides C{RESPONSES} defined in L{_response} are
        integers and are keys in C{RESPONSES}.
        Ú	RESPONSESc                 s   s    | ]}|d kp|t jkV  qdS )Ú_N)ÚstringZascii_uppercase)Ú.0Úc© r   úF/usr/lib/python3/dist-packages/twisted/web/test/test_web__responses.pyÚ	<genexpr>   s     z/ResponseTests.test_constants.<locals>.<genexpr>N)Údirr   ÚallÚgetattrZassertIsInstanceÚintZassertInr   )ÚselfZsymÚvalr   r   r   Útest_constants   s    
zResponseTests.test_constantsN)Ú__name__Ú
__module__Ú__qualname__r   r   r   r   r   r      s   r   )Ú__doc__Z
__future__r   r   r	   Ztwisted.trialr   Ztwisted.webr   ZTestCaser   r   r   r   r   Ú<module>   s
   