summaryrefslogtreecommitdiffstats
path: root/Lib/test/pickletester.py
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2017-05-02 18:56:52 (GMT)
committerGitHub <noreply@github.com>2017-05-02 18:56:52 (GMT)
commit8e158b2316385497c7b6b818d8b45855d7f87f0b (patch)
treefe4c610d813981f25afd0a818be02e87ad21b54a /Lib/test/pickletester.py
parent43566aee12a177a7aef5d732abf768251e6b8a12 (diff)
downloadcpython-8e158b2316385497c7b6b818d8b45855d7f87f0b.zip
cpython-8e158b2316385497c7b6b818d8b45855d7f87f0b.tar.gz
cpython-8e158b2316385497c7b6b818d8b45855d7f87f0b.tar.bz2
[2.7] bpo-30223: Fix test_xpickle for Python 2.4. (#1395)
Diffstat (limited to 'Lib/test/pickletester.py')
-rw-r--r--Lib/test/pickletester.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/Lib/test/pickletester.py b/Lib/test/pickletester.py
index 4268394..0256bca 100644
--- a/Lib/test/pickletester.py
+++ b/Lib/test/pickletester.py
@@ -1,6 +1,4 @@
# -*- coding: utf-8 -*-
-from __future__ import absolute_import
-
import unittest
import pickle
import cPickle
@@ -169,7 +167,7 @@ class K(object):
# Shouldn't support the recursion itself
return K, (self.value,)
-import __main__
+__main__ = sys.modules['__main__']
__main__.C = C
C.__module__ = "__main__"
__main__.D = D