summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_htmlparser.py
diff options
context:
space:
mode:
authorAndrew M. Kuchling <amk@amk.ca>2004-06-05 15:31:45 (GMT)
committerAndrew M. Kuchling <amk@amk.ca>2004-06-05 15:31:45 (GMT)
commitb7d8ce0275d7b4c9a9c2312d0add835c6eac1730 (patch)
tree444603ff2dbf2002db0ff976d64f16516be4bbe7 /Lib/test/test_htmlparser.py
parent9021c955951c63ef3075b4751615af329427d3ec (diff)
downloadcpython-b7d8ce0275d7b4c9a9c2312d0add835c6eac1730.zip
cpython-b7d8ce0275d7b4c9a9c2312d0add835c6eac1730.tar.gz
cpython-b7d8ce0275d7b4c9a9c2312d0add835c6eac1730.tar.bz2
[Bug #921657] Allow '@' in unquoted HTML attributes. Not strictly legal according to the HTML REC, but HTMLParser is already a pretty loose parser. Reported by Bernd Zimmermann.
Diffstat (limited to 'Lib/test/test_htmlparser.py')
-rwxr-xr-xLib/test/test_htmlparser.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/test/test_htmlparser.py b/Lib/test/test_htmlparser.py
index a830ed7..5b4bd56 100755
--- a/Lib/test/test_htmlparser.py
+++ b/Lib/test/test_htmlparser.py
@@ -204,6 +204,10 @@ DOCTYPE html [
self._run_check("<e a=rgb(1,2,3)>", [
("starttag", "e", [("a", "rgb(1,2,3)")]),
])
+ # Regression test for SF bug #921657.
+ self._run_check("<a href=mailto:xyz@example.com>", [
+ ("starttag", "a", [("href", "mailto:xyz@example.com")]),
+ ])
def test_attr_entity_replacement(self):
self._run_check("""<a b='&amp;&gt;&lt;&quot;&apos;'>""", [