diff options
Diffstat (limited to 'tests/manual_test.py')
-rw-r--r-- | tests/manual_test.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/tests/manual_test.py b/tests/manual_test.py index ad6b2b9b..ce8d10f2 100644 --- a/tests/manual_test.py +++ b/tests/manual_test.py @@ -2,10 +2,14 @@ import os import shutil import tempfile -import urllib2 import subprocess import sys +if sys.version_info[0] < 3: + from urllib2 import urlopen +else: + from urllib.request import urlopen + def tempdir(func): def _tempdir(*args, **kwargs): test_dir = tempfile.mkdtemp() @@ -61,7 +65,7 @@ def test_full(): f.write(SIMPLE_BUILDOUT) with open('bootstrap.py', 'w') as f: - f.write(urllib2.urlopen(BOOTSTRAP).read()) + f.write(urlopen(BOOTSTRAP).read()) os.system('bin/python bootstrap.py --distribute') os.system('bin/buildout -q') |