@@ -13,15 +13,15 @@ THIS FAILS IN libxml2 2.6.29 AND 2.6.30 !!
1313... return s
1414
1515>>> doc_embed = '''<div>
16- ... <embed src="http://www.youtube.com/v/183tVH1CZpA" type="application/x-shockwave-flash"></embed>
17- ... <embed src="http://anothersite.com/v/another"></embed>
16+ ... <embed src="http://www.youtube.com/v/183tVH1CZpA" type="application/x-shockwave-flash">
17+ ... <embed src="http://anothersite.com/v/another">
1818... <script src="http://www.youtube.com/example.js"></script>
1919... <script src="/something-else.js"></script>
2020... </div>'''
2121>>> print(tostring(fromstring(doc_embed)))
2222<div>
23- <embed src="http://www.youtube.com/v/183tVH1CZpA" type="application/x-shockwave-flash"></embed>
24- <embed src="http://anothersite.com/v/another"></embed>
23+ <embed src="http://www.youtube.com/v/183tVH1CZpA" type="application/x-shockwave-flash">
24+ <embed src="http://anothersite.com/v/another">
2525<script src="http://www.youtube.com/example.js"></script>
2626<script src="/something-else.js"></script>
2727</div>
@@ -30,10 +30,10 @@ THIS FAILS IN libxml2 2.6.29 AND 2.6.30 !!
3030</div>
3131>>> print(Cleaner(host_whitelist=['www.youtube.com']).clean_html(doc_embed))
3232<div>
33- <embed src="http://www.youtube.com/v/183tVH1CZpA" type="application/x-shockwave-flash"></embed>
33+ <embed src="http://www.youtube.com/v/183tVH1CZpA" type="application/x-shockwave-flash">
3434</div>
3535>>> print(Cleaner(host_whitelist=['www.youtube.com'], whitelist_tags=None).clean_html(doc_embed))
3636<div>
37- <embed src="http://www.youtube.com/v/183tVH1CZpA" type="application/x-shockwave-flash"></embed>
37+ <embed src="http://www.youtube.com/v/183tVH1CZpA" type="application/x-shockwave-flash">
3838<script src="http://www.youtube.com/example.js"></script>
3939</div>
0 commit comments