[Python-checkins] python/dist/src/Lib/test regrtest.py,1.73,1.74
fdrake@sourceforge.net
fdrake@sourceforge.net
Thu, 11 Apr 2002 09:39:19 -0700
Update of /cvsroot/python/python/dist/src/Lib/test
In directory usw-pr-cvs1:/tmp/cvs-serv22978/Lib/test
Modified Files:
regrtest.py
Log Message:
Added the resource name "all" to enable all of the optional resource uses.
This is nice for use with "make TESTOPTS='-u all' test".
Index: regrtest.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/test/regrtest.py,v
retrieving revision 1.73
retrieving revision 1.74
diff -C2 -d -r1.73 -r1.74
*** regrtest.py 1 Apr 2002 05:04:46 -0000 1.73
--- regrtest.py 11 Apr 2002 16:39:16 -0000 1.74
***************
*** 37,40 ****
--- 37,42 ----
only the following are defined:
+ all - Enable all special resources.
+
curses - Tests that use curses and will modify the terminal's
state and output modes.
***************
*** 57,60 ****
--- 59,66 ----
import test_support
+
+ RESOURCE_NAMES = ('curses', 'largefile', 'network')
+
+
def usage(code, msg=''):
print __doc__
***************
*** 122,127 ****
u = [x.lower() for x in a.split(',')]
for r in u:
! if r not in ('curses', 'largefile', 'network'):
! usage(1, 'Invalid -u/--use option: %s' % a)
use_resources.extend(u)
if generate and verbose:
--- 128,136 ----
u = [x.lower() for x in a.split(',')]
for r in u:
! if r == 'all':
! use_resources = RESOURCE_NAMES
! break
! if r not in RESOURCE_NAMES:
! usage(1, 'Invalid -u/--use option: ' + a)
use_resources.extend(u)
if generate and verbose: