Commit 9418f48c authored by Jason R. Coombs's avatar Jason R. Coombs

Updated install_test to reference the new bootstrap script

--HG--
branch : Setuptools-Distribute merge
extra : rebase_source : ae9d4dbfa6770634bf65bba6f0b6f236074aa9d5
parent 7a12d0b7
...@@ -2,8 +2,10 @@ import urllib2 ...@@ -2,8 +2,10 @@ import urllib2
import sys import sys
import os import os
if os.path.exists('distribute_setup.py'): bootstrap_name = 'ez_setup.py'
print 'distribute_setup.py exists in the current dir, aborting'
if os.path.exists(bootstrap_name):
print bootstrap_name + ' exists in the current dir, aborting'
sys.exit(2) sys.exit(2)
print '**** Starting Test' print '**** Starting Test'
...@@ -14,24 +16,28 @@ if is_jython: ...@@ -14,24 +16,28 @@ if is_jython:
import subprocess import subprocess
print 'Downloading bootstrap' print 'Downloading bootstrap'
file = urllib2.urlopen('http://nightly.ziade.org/distribute_setup.py') file = urllib2.urlopen('https://bitbucket.org/jaraco/setuptools-private'
f = open('distribute_setup.py', 'w') '/src/tip/' + bootstrap_name)
f = open(bootstrap_name, 'w')
f.write(file.read()) f.write(file.read())
f.close() f.close()
# running it # running it
args = [sys.executable] + ['distribute_setup.py'] args = [sys.executable, bootstrap_name]
if is_jython: if is_jython:
res = subprocess.call(args) res = subprocess.call(args)
else: else:
res = os.spawnv(os.P_WAIT, sys.executable, args) res = os.spawnv(os.P_WAIT, sys.executable, args)
fail_message = ('**** Test failed; please report the output to the '
'setuptools bugtracker.')
if res != 0: if res != 0:
print '**** Test failed, please send me the output at tarek@ziade.org' print(fail_message)
os.remove('distribute_setup.py') os.remove(bootstrap_name)
sys.exit(2) sys.exit(2)
# now checking if Distribute is installed # now checking if Setuptools is installed
script = """\ script = """\
import sys import sys
try: try:
...@@ -67,9 +73,9 @@ try: ...@@ -67,9 +73,9 @@ try:
if res: if res:
print '**** Test is OK' print '**** Test is OK'
else: else:
print '**** Test failed, please send me the output at tarek@ziade.org' print(fail_message)
finally: finally:
if os.path.exists(script_name): if os.path.exists(script_name):
os.remove(script_name) os.remove(script_name)
os.remove('distribute_setup.py') os.remove(bootstrap_name)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment