viff

changeset 603:2ab7f8d9f28c

Merged with Thomas.
author Martin Geisler <mg@daimi.au.dk>
date Mon, 24 Mar 2008 13:23:17 +0100
parents 1ad9f7991c7c e5273143bf1f
children 7bf246416d4c
files
diffstat 1 files changed, 14 insertions(+), 1 deletions(-) [+]
line diff
     1.1 --- a/run.py	Mon Mar 24 13:16:28 2008 +0100
     1.2 +++ b/run.py	Mon Mar 24 13:23:17 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():