summaryrefslogtreecommitdiffstats
path: root/Lib/test/regrtest.py
diff options
context:
space:
mode:
authorAlexandre Vassalotti <alexandre@peadrop.com>2008-05-11 08:55:36 (GMT)
committerAlexandre Vassalotti <alexandre@peadrop.com>2008-05-11 08:55:36 (GMT)
commitf7fa63dd55e638d300a8d4a148dcedb402fdb750 (patch)
tree53cc22a0517f95753d4772c11f1c247a7c30fa8b /Lib/test/regrtest.py
parent7760008c38b6a88dfdc675d97668763a7c1cacd2 (diff)
downloadcpython-f7fa63dd55e638d300a8d4a148dcedb402fdb750.zip
cpython-f7fa63dd55e638d300a8d4a148dcedb402fdb750.tar.gz
cpython-f7fa63dd55e638d300a8d4a148dcedb402fdb750.tar.bz2
Rename copy_reg module to copyreg.
Updated documentation. Merged revisions 63042 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r63042 | alexandre.vassalotti | 2008-05-11 04:25:28 -0400 (Sun, 11 May 2008) | 5 lines Added module stub for copy_reg renaming in 3.0. Renamed copy_reg to copyreg in the standard library, to avoid spurious warnings and ease later merging to py3k branch. Public documentation remains intact. ........
Diffstat (limited to 'Lib/test/regrtest.py')
-rwxr-xr-xLib/test/regrtest.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/test/regrtest.py b/Lib/test/regrtest.py
index bbc81bc..f87b8a8 100755
--- a/Lib/test/regrtest.py
+++ b/Lib/test/regrtest.py
@@ -676,7 +676,7 @@ def cleanup_test_droppings(testname, verbose):
def dash_R(the_module, test, indirect_test, huntrleaks):
# This code is hackish and inelegant, but it seems to do the job.
- import copy_reg, _abcoll
+ import copyreg, _abcoll
if not hasattr(sys, 'gettotalrefcount'):
raise Exception("Tracking reference leaks requires a debug build "
@@ -684,7 +684,7 @@ def dash_R(the_module, test, indirect_test, huntrleaks):
# Save current values for dash_R_cleanup() to restore.
fs = warnings.filters[:]
- ps = copy_reg.dispatch_table.copy()
+ ps = copyreg.dispatch_table.copy()
pic = sys.path_importer_cache.copy()
abcs = {}
for abc in [getattr(_abcoll, a) for a in _abcoll.__all__]:
@@ -724,7 +724,7 @@ def dash_R(the_module, test, indirect_test, huntrleaks):
refrep.close()
def dash_R_cleanup(fs, ps, pic, abcs):
- import gc, copy_reg
+ import gc, copyreg
import _strptime, linecache
import urlparse, urllib, urllib2, mimetypes, doctest
import struct, filecmp, _abcoll
@@ -738,8 +738,8 @@ def dash_R_cleanup(fs, ps, pic, abcs):
# Restore some original values.
warnings.filters[:] = fs
- copy_reg.dispatch_table.clear()
- copy_reg.dispatch_table.update(ps)
+ copyreg.dispatch_table.clear()
+ copyreg.dispatch_table.update(ps)
sys.path_importer_cache.clear()
sys.path_importer_cache.update(pic)