revert creation of the html.entities and html.parser modules
(http://bugs.python.org/issue2882)
diff --git a/Lib/test/test_codeccallbacks.py b/Lib/test/test_codeccallbacks.py
index a0fa343..656551d 100644
--- a/Lib/test/test_codeccallbacks.py
+++ b/Lib/test/test_codeccallbacks.py
@@ -1,5 +1,5 @@
import test.test_support, unittest
-import sys, codecs, html.entities, unicodedata
+import sys, codecs, htmlentitydefs, unicodedata
class PosReturn:
# this can be used for configurable callbacks
@@ -86,7 +86,7 @@
l = []
for c in exc.object[exc.start:exc.end]:
try:
- l.append(u"&%s;" % html.entities.codepoint2name[ord(c)])
+ l.append(u"&%s;" % htmlentitydefs.codepoint2name[ord(c)])
except KeyError:
l.append(u"&#%d;" % ord(c))
return (u"".join(l), exc.end)
diff --git a/Lib/test/test_multibytecodec_support.py b/Lib/test/test_multibytecodec_support.py
index b9aa34b..6055764 100644
--- a/Lib/test/test_multibytecodec_support.py
+++ b/Lib/test/test_multibytecodec_support.py
@@ -64,7 +64,7 @@
if self.has_iso10646:
return
- from html.entities import codepoint2name
+ from htmlentitydefs import codepoint2name
def xmlcharnamereplace(exc):
if not isinstance(exc, UnicodeEncodeError):
diff --git a/Lib/test/test_py3kwarn.py b/Lib/test/test_py3kwarn.py
index d64d66a..eb28b89 100644
--- a/Lib/test/test_py3kwarn.py
+++ b/Lib/test/test_py3kwarn.py
@@ -216,13 +216,11 @@
class TestStdlibRenames(unittest.TestCase):
renames = {'copy_reg': 'copyreg', 'Queue': 'queue',
- 'htmlentitydefs': 'html.entities',
'SocketServer': 'socketserver',
'ConfigParser': 'configparser',
'repr': 'reprlib',
'FileDialog': 'tkinter.filedialog',
'FixTk': 'tkinter._fix',
- 'HTMLParser': 'html.parser',
'ScrolledText': 'tkinter.scrolledtext',
'SimpleDialog': 'tkinter.simpledialog',
'Tix': 'tkinter.tix',
diff --git a/Lib/test/test_sundry.py b/Lib/test/test_sundry.py
index c2fb66d..404a405 100644
--- a/Lib/test/test_sundry.py
+++ b/Lib/test/test_sundry.py
@@ -50,7 +50,7 @@
import encodings
import formatter
import getpass
- import html.entities
+ import htmlentitydefs
import ihooks
import imghdr
import imputil