viff

changeset 602:e5273143bf1f

Fixed problem with Windows XP buildbot slave. Twisted Trial on Windows XP needs the SYSTEMROOT environment variable to be set in order to work. This variable is now properly set in the run.py script. See http://tracker.viff.dk/issue18.
author Thomas Pelle Jakobsen <mas@daimi.au.dk>
date Mon, 24 Mar 2008 13:02:20 +0100
parents 46bd23052806
children 2ab7f8d9f28c
files run.py
diffstat 1 files changed, 14 insertions(+), 1 deletions(-) [+]
line diff
     1.1 --- a/run.py	Mon Mar 24 01:04:29 2008 +0100
     1.2 +++ b/run.py	Mon Mar 24 13:02:20 2008 +0100
     1.3 @@ -217,11 +217,24 @@
     1.4      """Find static errors using Pyflakes."""
     1.5      execute(['pyflakes', '.'])
     1.6  
     1.7 +
     1.8  @command('trial', 'python')
     1.9  def trial(python):
    1.10      """Execute Trial using the Python executable given."""
    1.11      trial = find_program("trial")
    1.12 -    execute([python, trial, '--reporter=bwverbose', 'viff.test'])
    1.13 +    trial_env = {}
    1.14 +
    1.15 +    # Twisted on Windows needs the SYSTEMROOT env variable, see
    1.16 +    # http://tracker.viff.dk/issue18
    1.17 +    if sys.platform == "win32":
    1.18 +        if os.environ['SYSTEMROOT']:
    1.19 +            trial_env['SYSTEMROOT'] = os.environ['SYSTEMROOT']
    1.20 +        else:
    1.21 +            abort("Twisted Trial needs SYSTEMROOT env variable.")
    1.22 +
    1.23 +    execute([python, trial, '--reporter=bwverbose', 'viff.test'],
    1.24 +            env=trial_env)
    1.25 +
    1.26  
    1.27  @command('help')
    1.28  def usage():