00217 :
00218
00219 import getopt
00220
00221 try:
00222 opts, args = getopt.getopt(argv, "dj:t:", ["nproc=", 'uploadDir=', 'tests=','noRun','dump'])
00223 except getopt.GetoptError, e:
00224 print "unknown option", str(e)
00225 sys.exit(2)
00226
00227 np = 4
00228 uploadDir = None
00229 runTests = True
00230 testList = None
00231 dump = False
00232 for opt, arg in opts :
00233 if opt in ('-j', "--nproc" ):
00234 np=int(arg)
00235 if opt in ("--uploadDir", ):
00236 uploadDir = arg
00237 if opt in ('--noRun', ):
00238 runTests = False
00239 if opt in ('-d','--dump', ):
00240 dump = True
00241 if opt in ('-t','--tests', ):
00242 testList = arg.split(",")
00243
00244 tester = StandardTester(np)
00245 if dump:
00246 tester.dumpTest()
00247 else:
00248 if runTests:
00249 tester.runTests(testList)
00250 if uploadDir:
00251 tester.upload(uploadDir)
00252 return