summaryrefslogtreecommitdiff
path: root/test/subclassing.py
diff options
context:
space:
mode:
authorSteven Knight <knight@baldmt.com>2010-04-07 15:29:39 +0000
committerSteven Knight <knight@baldmt.com>2010-04-07 15:29:39 +0000
commite6ef7740ee9b9896f8ee84bc51de31df7d109952 (patch)
treeeb60dd8251a7fd064aa255309df2056dbf49a258 /test/subclassing.py
parente484c24f3ea5168bb420a715913da1bca156a0a2 (diff)
downloadscons-e6ef7740ee9b9896f8ee84bc51de31df7d109952.tar.gz
Issue 2334: Use compatibility versions of collections.User{Dict,List,String}
instead of the deprecated User{Dict,List,String} modules. The two test scripts that use User{List,String} fall back on ImportError by hand.
Diffstat (limited to 'test/subclassing.py')
-rw-r--r--test/subclassing.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/test/subclassing.py b/test/subclassing.py
index 655de519..fc003498 100644
--- a/test/subclassing.py
+++ b/test/subclassing.py
@@ -51,7 +51,10 @@ class my_Environment(Environment):
env = my_Environment()
env.Command('f0.out', 'f0.in', copy_action)
-from UserString import UserString
+try:
+ from io import UserString
+except ImportError:
+ from UserString import UserString
try:
class mystr(str):
pass