File: D:/Python311/Lib/site-packages/bs4/tests/__pycache__/test_tree.cpython-311.pyc
�
��ncŹ � �N � d Z ddlmZ ddlZddlZddlZddlmZ ddlm Z m
Z
ddlmZm
Z
mZmZmZmZmZmZmZmZmZ ddlmZmZ G d � d
e� � Z G d� de� � Z G d
� de� � Z G d� de� � Z G d� de� � Z G d� de� � Z G d� de� � Z G d� de� � Z! G d� de� � Z" G d� de"� � Z# G d� de"� � Z$ G d� d e� � Z% G d!� d"e%� � Z& G d#� d$e%� � Z' G d%� d&e� � Z( G d'� d(e� � Z)dS ))a8 Tests for Beautiful Soup's tree traversal methods.
The tree traversal methods are the main advantage of using Beautiful
Soup over just using a parser.
Different parsers will build different Beautiful Soup trees given the
same markup, but all Beautiful Soup trees can be traversed with the
methods tested here.
� )� set_traceN)�
BeautifulSoup)�builder_registry�HTMLParserTreeBuilder)�CData�Comment�Declaration�Doctype� Formatter�NavigableString�Script�SoupStrainer�
Stylesheet�Tag�TemplateString� )�SoupTest�skipIfc �0 � e Zd ZdZd� Zd� Zd� Zd� Zd� ZdS )�TestFindz�Basic tests of the find() method.
find() just calls find_all() with limit=1, so it's not tested all
that thouroughly here.
c �p � | � d� � }|� d� � j dk sJ �d S )Nz <a>1</a><b>2</b><a>3</a><b>4</b>�b�2)�soup�find�string��selfr s �5D:\Python311\Lib\site-packages\bs4/tests/test_tree.py�
test_find_tagzTestFind.test_find_tag. s8 � ��y�y�;�<�<���y�y��~�~�$��+�+�+�+�+�+� c �h � | � d� � }|� d�� � dk sJ �d S )Nu <h1>Räksmörgås</h1>�
Räksmörgås�r )r r r s r �test_unicode_text_findzTestFind.test_unicode_text_find2 s9 � ��y�y�1�2�2���y�y��y�0�0�O�C�C�C�C�C�Cr! c � � | � d� � }t |� � d|� d�� � j k sJ �d S )Nu&