X-Git-Url: http://git.bitcoin.ninja/index.cgi?p=youtube-dl;a=blobdiff_plain;f=test%2Ftest_utils.py;h=2b93b360477f857b8fa693450d3c5375db5663cc;hp=41b094d89f7bf80bdd49d15dcf60f65d3b02ce23;hb=b4a3d461e4a00dfc60047b667aa3136c8b03eda8;hpb=72b409559c984bb116015ada55acd38120b24cc0 diff --git a/test/test_utils.py b/test/test_utils.py index 41b094d89..2b93b3604 100644 --- a/test/test_utils.py +++ b/test/test_utils.py @@ -916,6 +916,8 @@ class TestUtil(unittest.TestCase): supports_outside_bmp = False if supports_outside_bmp: self.assertEqual(extract_attributes(''), {'x': 'Smile \U0001f600!'}) + # Malformed HTML should not break attributes extraction on older Python + self.assertEqual(extract_attributes(''), {}) def test_clean_html(self): self.assertEqual(clean_html('a:\nb'), 'a: b')