diff options
author | Steven Knight <knight@baldmt.com> | 2001-11-16 22:06:52 (GMT) |
---|---|---|
committer | Steven Knight <knight@baldmt.com> | 2001-11-16 22:06:52 (GMT) |
commit | 76166c77f852377b6139a9414cc355fe2661a0e7 (patch) | |
tree | fe77db2a491d0f8f0aa6c743c1e1f5b21a1914ed /runtest.py | |
parent | 9508d219188fcd2ad8eb2d24606d1b9c611e9ed2 (diff) | |
download | SCons-76166c77f852377b6139a9414cc355fe2661a0e7.zip SCons-76166c77f852377b6139a9414cc355fe2661a0e7.tar.gz SCons-76166c77f852377b6139a9414cc355fe2661a0e7.tar.bz2 |
Add the scons package.
Diffstat (limited to 'runtest.py')
-rw-r--r-- | runtest.py | 29 |
1 files changed, 20 insertions, 9 deletions
@@ -16,6 +16,13 @@ # # Options: # +# -1 Use the test configuration in build/test1 +# (installed from the scons package) +# +# -2 Use the test configuration in build/test2 +# (installed from the python-scons and scons-script +# packages) +# # -a Run all tests; does a virtual 'find' for # all SCons tests under the current directory. # @@ -47,12 +54,15 @@ debug = '' tests = [] printcmd = 1 version = None +testver = 1 -opts, tests = getopt.getopt(sys.argv[1:], "ab:dqv:", +opts, tests = getopt.getopt(sys.argv[1:], "12ab:dqv:", ['all','build=','debug','quiet','version=']) for o, a in opts: - if o == '-a' or o == '--all': all = 1 + if o == '-1': testver = 1 + elif o == '-2': testver = 2 + elif o == '-a' or o == '--all': all = 1 elif o == '-b' or o == '--build': build = a elif o == '-d' or o == '--debug': debug = os.path.join( sys.exec_prefix, @@ -100,14 +110,15 @@ if build == 'aegis': version = aegis_to_version(version) - scons_dir = os.path.join(cwd, 'build', 'test', 'bin') + scons_dir = os.path.join(cwd, 'build', 'test' + str(testver), 'bin') + + if testver == 1: + test_dir = os.path.join('test1', 'lib', 'scons-' + str(version)) + elif testver == 2: + test_dir = os.path.join('test2', 'lib', 'python' + sys.version[0:3], + 'site-packages') - os.environ['PYTHONPATH'] = os.path.join(cwd, - 'build', - 'test', - 'lib', - 'python' + sys.version[0:3], - 'site-packages') + os.environ['PYTHONPATH'] = os.path.join(cwd, 'build', test_dir) else: |