
    OwgI	                     T    d Z ddlmZmZmZ ddlmZ  G d de      Z G d de      Z	y	)
zTests of classes in element.py.

The really big classes -- Tag, PageElement, and NavigableString --
are tested in separate files.
    )CharsetMetaAttributeValueContentMetaAttributeValueNamespacedAttribute   )SoupTestc                   $    e Zd Zd Zd Zd Zd Zy)TestNamedspacedAttributec                 t    t        dd       }|dk(  sJ t        dd      }|dk(  sJ t        d      }|dk(  sJ y )Nxmlns r   selfas     M/var/www/horilla/myenv/lib/python3.12/site-packages/bs4/tests/test_element.py test_name_may_be_none_or_missingz9TestNamedspacedAttribute.test_name_may_be_none_or_missing   sH    .G||,G||(G||    c                 P    t        d d      }|dk(  sJ t        dd      }|dk(  sJ y )Ntagr   r   r   s     r   %test_namespace_may_be_none_or_missingz>TestNamedspacedAttribute.test_namespace_may_be_none_or_missing   s2    e,EzzE*Ezzr   c                 *    t        dd      }d|k(  sJ y )Nr   bza:br   r   s     r   6test_attribute_is_equivalent_to_colon_separated_stringzOTestNamedspacedAttribute.test_attribute_is_equivalent_to_colon_separated_string"   s    S)zzr   c                     t        ddd      }t        ddd      }||k(  sJ t        ddd       }||k(  sJ t        ddd      }||k7  sJ t        ddd      }||k7  sJ y )Nr   r   czr   )r   r   r   r   des         r   ;test_attributes_are_equivalent_if_prefix_and_name_identicalzTTestNamedspacedAttribute.test_attributes_are_equivalent_if_prefix_and_name_identical&   sx    S#.S#.Avv  S$/Avv  S#.AvvS#.Avvr   N)__name__
__module____qualname__r   r   r   r    r   r   r	   r	      s    r   r	   c                       e Zd ZdZd Zd Zy))TestAttributeValueWithCharsetSubstitutionzpCertain attributes are designed to have the charset of the
    final document substituted into their value.
    c                     t        d      }d|k(  sJ d|j                  k(  sJ d|j                  d      k(  sJ d|j                  d      k(  sJ y )Nzeuc-jputf8ascii)r   original_valueencoder   values     r   !test_content_meta_attribute_valuezKTestAttributeValueWithCharsetSubstitution.test_content_meta_attribute_value<   s^     *(35   5/////f----%,,w////r   c                     t        d      }d|k(  sJ d|j                  k(  sJ d|j                  d      k(  sJ d|j                  d      k(  sJ y )Nztext/html; charset=euc-jpztext/html; charset=utf8r'   ztext/html; charset=asciir(   )r   r)   r*   r+   s     r   r-   zKTestAttributeValueWithCharsetSubstitution.test_content_meta_attribute_valueE   s]    )*EF*e333*e.B.BBBB(ELL,@@@@)U\\'-BBBBr   N)r    r!   r"   __doc__r-   r#   r   r   r%   r%   7   s    0Cr   r%   N)
r/   bs4.elementr   r   r   r   r   objectr	   r%   r#   r   r   <module>r2      s4    
 %v %PC Cr   