Warning: session_start(): Session cannot be started after headers have already been sent in /home/tvrreohg/public_html/manga.php on line 13
3 6]+@sdZddlZyddlmZdZWn&ek rFZz dZWYddZ[XnXddlmZddl m Z m Z m Z e e dGd d d e e Z dS) zDTests to ensure that the html5lib tree builder generates good trees.N)HTML5TreeBuilderTF) SoupStrainer)HTML5TreeBuilderSmokeTestSoupTestskipIfz?html5lib seems not to be present, not testing its tree builder.c@sleZdZdZeddZddZddZdd Zd d Z d d Z ddZ ddZ ddZ ddZddZdS)HTML5LibBuilderSmokeTestz"See ``HTML5TreeBuilderSmokeTest``.cCstS)N)r)selfr #/usr/lib/python3.6/test_html5lib.pydefault_buildersz(HTML5LibBuilderSmokeTest.default_builderc Csdtd}d}tjdd}|j||d}WdQRX|j|j|j||jdt|dj kdS)Nbz

A bold statement.

T)record)Z parse_onlyz4the html5lib tree builder doesn't support parse_onlyr) rwarningscatch_warningssoup assertEqualdecodeZ document_forZ assertTruestrmessage)rZstrainermarkupwrr r r test_soupstrainersz*HTML5LibBuilderSmokeTest.test_soupstrainercCsd}|j|d|jddS)z8html5lib inserts tags where other parsers don't.z[z
Here's another table:
foo
Here's another table:
foo
z{
Foo
Bar
Baz
N)ZassertSoupEquals)rrr r r test_correctly_nested_tables(s z5HTML5LibBuilderSmokeTest.test_correctly_nested_tablescCs$d}|j|}|jd|jjdS)Nzy

foo

s

foo

)rrpencode)rrrr r r (test_xml_declaration_followed_by_doctype<s  zAHTML5LibBuilderSmokeTest.test_xml_declaration_followed_by_doctypecCs:d}|j|}|jd|jj|jdt|jddS)Nz%

foo

bar

zD

foo

bar

r)rrbodyrlenfind_all)rrrr r r test_reparented_markupJs z/HTML5LibBuilderSmokeTest.test_reparented_markupcCs:d}|j|}|jd|jj|jdt|jddS)Nz&

foo

bar

zE

foo

bar

rr)rrrrrr)rrrr r r +test_reparented_markup_ends_with_whitespaceQs zDHTML5LibBuilderSmokeTest.test_reparented_markup_ends_with_whitespacecCs0d}|j|}|jdd\}}|jd\}}dS)zVerify that we keep the two whitespace nodes in this document distinct when reparenting the adjacent tags. z,
 )stringZtbodyN)rr)rrrZspace1Zspace2Ztbody1Ztbody2r r r aftermath

aftermath

target)r#Z aftermath)rnoscriptrZ next_elementfindrZprevious_element)rrrr(r%Zfinal_aftermathr r r *test_reparented_markup_containing_childrenbs  zCHTML5LibBuilderSmokeTest.test_reparented_markup_containing_childrencCsd}|j|}dS)z(Processing instructions become comments.sN)r)rrrr r r test_processing_instructionrs z4HTML5LibBuilderSmokeTest.test_processing_instructioncCs,d}|j|}|jd\}}|j||dS)Ns

a)rrr)rrrZa1Za2r r r test_cloned_multivalue_nodexs   z4HTML5LibBuilderSmokeTest.test_cloned_multivalue_nodecCs$d}|j|}|jd|jjdS)NsAz>A
)rrrr)rrrr r r test_foster_parentings z.HTML5LibBuilderSmokeTest.test_foster_parentingN)__name__ __module__ __qualname____doc__propertyr rrrr r!r$r*r+r-r.r r r r rs   r)r2rZ bs4.builderrZHTML5LIB_PRESENT ImportErroreZ bs4.elementrZ bs4.testingrrrrr r r r s