Index: twisted/python/usage.py =================================================================== RCS file: /cvs/Twisted/twisted/python/usage.py,v retrieving revision 1.45 diff -u -r1.45 usage.py --- twisted/python/usage.py 20 Jul 2003 09:55:01 -0000 1.45 +++ twisted/python/usage.py 3 Aug 2003 23:16:21 -0000 @@ -129,9 +129,8 @@ self._gather_handlers, ] - for (longOpt, shortOpt, docs, settings, synonyms, dispatch)\ - in map( lambda c: c(), collectors): - + for c in collectors: + (longOpt, shortOpt, docs, settings, synonyms, dispatch) = c() self.longOpt.extend(longOpt) self.shortOpt = self.shortOpt + shortOpt self.docs.update(docs) @@ -345,7 +344,7 @@ #docs[name] = string.split(doc, '\n')[0] docs[prettyName] = doc else: - docs[prettyName] = None + docs[prettyName] = self.docs.get(prettyName) synonyms[prettyName] = prettyName Index: twisted/scripts/trial.py =================================================================== RCS file: /cvs/Twisted/twisted/scripts/trial.py,v retrieving revision 1.46 diff -u -r1.46 trial.py --- twisted/scripts/trial.py 19 Jul 2003 21:36:49 -0000 1.46 +++ twisted/scripts/trial.py 3 Aug 2003 23:16:22 -0000 @@ -19,6 +19,7 @@ # - Hangs. from twisted.python import usage, reflect, failure +from twisted.scripts.twistd import reactorTypes from twisted.trial import unittest, util, reporter as reps import sys, os, types, inspect import re @@ -39,7 +40,7 @@ ["recurse", "R", "Search packages recursively"]] optParameters = [["reactor", "r", None, - "The Twisted reactor to install before running the tests (looked up as a module contained in twisted.internet)"], + 'Which reactor to use out of: %s.' % ', '.join(reactorTypes.keys())], ["logfile", "l", "test.log", "log file name"], ["random", "z", None, "Run tests in random order using the specified seed"], @@ -58,10 +59,11 @@ def opt_reactor(self, reactorName): # this must happen before parseArgs does lots of imports - mod = 'twisted.internet.' + reactorName + mod = reactorTypes.get(reactorName) + if mod is None: mod = 'twisted.internet.' + reactorName print "Using %s reactor" % mod reflect.namedModule(mod).install() - + def opt_testmodule(self, file): "Module to find a test case for" # only look at the first two lines of the file. Try to behave as