Ë
    ojý  ã                   óR   — d dl mZ d dlmZ d dlmZ  G d„ dej                  «      Zy)é    )Útext)Ú
attributes)Úunittestc                   óX   — e Zd ZdZdd„Zdd„Zdd„Zdd„Zdd„Zdd„Z	dd	„Z
dd
„Zdd„Zy)ÚFormattedTextTestsz.
    Tests for assembling formatted text.
    Nc                 óp   — | j                  t        j                  t        j                  d   «      d«       y)zu
        Using no formatting attributes produces no VT102 control sequences in
        the flattened output.
        úHello, world.N)ÚassertEqualr   ÚassembleFormattedTextÚAÚnormal©Úselfs    ú>/usr/lib/python3/dist-packages/twisted/conch/test/test_text.pyÚtest_trivialzFormattedTextTests.test_trivial   s+   € ð
 	×ÑÜ×&Ñ&¤q§x¡x°Ñ'@ÓAÀ?õ	
ó    c                 óp   — | j                  t        j                  t        j                  d   «      d«       y)zƒ
        The bold formatting attribute, L{A.bold}, emits the VT102 control
        sequence to enable bold when flattened.
        r	   z[1mHello, world.N)r
   r   r   r   Úboldr   s    r   Ú	test_boldzFormattedTextTests.test_bold   s,   € ð
 	×ÑÜ×&Ñ&¤q§v¡v¨oÑ'>Ó?ÐAWõ	
r   c                 óp   — | j                  t        j                  t        j                  d   «      d«       y)z”
        The underline formatting attribute, L{A.underline}, emits the VT102
        control sequence to enable underlining when flattened.
        r	   z[4mHello, world.N)r
   r   r   r   Ú	underliner   s    r   Útest_underlinez!FormattedTextTests.test_underline!   s,   € ð
 	×ÑÜ×&Ñ&¤q§{¡{°?Ñ'CÓDØ"õ	
r   c                 óp   — | j                  t        j                  t        j                  d   «      d«       y)z‰
        The blink formatting attribute, L{A.blink}, emits the VT102 control
        sequence to enable blinking when flattened.
        r	   z[5mHello, world.N)r
   r   r   r   Úblinkr   s    r   Ú
test_blinkzFormattedTextTests.test_blink+   s,   € ð
 	×ÑÜ×&Ñ&¤q§w¡w¨Ñ'?Ó@ÐBXõ	
r   c                 óp   — | j                  t        j                  t        j                  d   «      d«       y)zž
        The reverse-video formatting attribute, L{A.reverseVideo}, emits the
        VT102 control sequence to enable reversed video when flattened.
        r	   z[7mHello, world.N)r
   r   r   r   ÚreverseVideor   s    r   Útest_reverseVideoz$FormattedTextTests.test_reverseVideo4   s,   € ð
 	×ÑÜ×&Ñ&¤q§~¡~°oÑ'FÓGØ"õ	
r   c           	      ó¼   — | j                  t        j                  t        j                  t        j
                  dt        j                  d    df      «      d«       y)zÉ
        Formatting attributes prefixed with a minus (C{-}) temporarily disable
        the prefixed attribute, emitting no VT102 control sequence to enable
        it in the flattened output.
        ÚHelloz worldú.z[1;5mHello[0;5m world[1;5m.N)r
   r   r   r   r   r   r   s    r   Ú
test_minuszFormattedTextTests.test_minus>   sM   € ð 	×ÑÜ×&Ñ&Ü—‘”q—w‘w˜w¬¯©°Ñ)9Ð(9¸3Ð>Ñ?Ñ@óð 6õ		
r   c                 óà   — | j                  t        j                  t        j                  t        j
                  j                  d   t        j
                  j                  d   f   «      d«       y)z£
        The foreground color formatting attribute, L{A.fg}, emits the VT102
        control sequence to set the selected foreground color when flattened.
        úHello, úworld!z[31mHello, [32mworld!N)r
   r   r   r   r   ÚfgÚredÚgreenr   s    r   Útest_foregroundz"FormattedTextTests.test_foregroundK   óP   € ð
 	×ÑÜ×&Ñ&Ü—‘œŸ™Ÿ™ )Ñ,¬a¯d©d¯j©j¸Ñ.BÐBÑCóð ,õ		
r   c                 óà   — | j                  t        j                  t        j                  t        j
                  j                  d   t        j
                  j                  d   f   «      d«       y)z£
        The background color formatting attribute, L{A.bg}, emits the VT102
        control sequence to set the selected background color when flattened.
        r$   r%   z[41mHello, [42mworld!N)r
   r   r   r   r   Úbgr'   r(   r   s    r   Útest_backgroundz"FormattedTextTests.test_backgroundW   r*   r   c                 óh  — | j                  | j                  g«      }| j                  t        |«      d«       t        j
                   | j                  | j                  g«      }| j                  t        |«      d«       | j                  |d   d   t        «       | j                  |d   d   d«       y)zv
        L{twisted.conch.insults.text.flatten} emits a deprecation warning when
        imported or accessed.
        r   é   ÚcategoryÚmessagez‚twisted.conch.insults.text.flatten was deprecated in Twisted 13.1.0: Use twisted.conch.insults.text.assembleFormattedText instead.N)ÚflushWarningsÚtest_flattenDeprecatedr
   Úlenr   ÚflattenÚDeprecationWarning)r   ÚwarningsShowns     r   r3   z)FormattedTextTests.test_flattenDeprecatedc   s¤   € ð
 ×*Ñ*¨D×,GÑ,GÐ+HÓIˆØ×Ñœ˜]Ó+¨QÔ/ô 	�Šà×*Ñ*¨D×,GÑ,GÐ+HÓIˆØ×Ñœ˜]Ó+¨QÔ/Ø×Ñ˜ qÑ)¨*Ñ5Ô7IÔJØ×ÑØ˜!Ñ˜YÑ'ðõ	
r   )ÚreturnN)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   r   r   r   r"   r)   r-   r3   © r   r   r   r   
   s4   „ ñó
ó
ó
ó
ó
ó
ó

ó

ô
r   r   N)	Útwisted.conch.insultsr   Útwisted.conch.insults.textr   r   Útwisted.trialr   ÚTestCaser   r=   r   r   ú<module>rB      s$   ðõ
 'Ý 6Ý "ôl
˜×*Ñ*õ l
r   