Mercurial > cpython-lru_cache-weakref
diff Lib/test/test_htmlparser.py @ 72270:9896fc2a8167 3.2
#12888: Fix a bug in HTMLParser.unescape that prevented it to escape more than 128 entities. Patch by Peter Otten.
| author | Ezio Melotti <ezio.melotti@gmail.com> |
|---|---|
| date | Mon, 05 Sep 2011 17:11:06 +0300 |
| parents | 225400cb6e84 |
| children | 41d41776aa6d |
line wrap: on
line diff
--- a/Lib/test/test_htmlparser.py Mon Sep 05 00:14:09 2011 +0200 +++ b/Lib/test/test_htmlparser.py Mon Sep 05 17:11:06 2011 +0300 @@ -377,7 +377,8 @@ p = html.parser.HTMLParser() self.assertEqual(p.unescape('&#bad;'),'&#bad;') self.assertEqual(p.unescape('&'),'&') - + # see #12888 + self.assertEqual(p.unescape('{ ' * 1050), '{ ' * 1050) def test_main(): support.run_unittest(HTMLParserTestCase, HTMLParserTolerantTestCase)
