def accept_args(args): args_spec = [ 'locate-root=', 'tag=', 'expected-results=', 'failures-markup=', 'comment=', 'results-dir=', 'results-prefix=', 'dont-collect-logs', 'reports=', 'user='******'upload', 'help' ] options = { '--comment': '', '--expected-results': '', '--failures-markup': '', '--reports': string.join(report_types, ','), '--tag': None, '--user': None, 'upload': False } utils.accept_args(args_spec, args, options, usage) if not options.has_key('--results-dir'): options['--results-dir'] = options['--locate-root'] if not options.has_key('--results-prefix'): options['--results-prefix'] = 'all' return (options['--locate-root'], options['--tag'], options['--expected-results'], options['--failures-markup'], options['--comment'], options['--results-dir'], options['--results-prefix'], options.has_key('--dont-collect-logs'), options['--reports'].split(','), options['--user'], options.has_key('--upload'))
def accept_args( args ): args_spec = [ 'locate-root=' , 'tag=' , 'expected-results=' , 'failures-markup=' , 'comment=' , 'results-dir=' , 'results-prefix=' , 'dont-collect-logs' , 'reports=' , 'v2' , 'user='******'upload' , 'help' ] options = { '--comment': '' , '--expected-results': '' , '--failures-markup': '' , '--reports': string.join( report_types, ',' ) , '--tag': None , '--user': None , 'upload': False } utils.accept_args( args_spec, args, options, usage ) if not options.has_key( '--results-dir' ): options[ '--results-dir' ] = options[ '--locate-root' ] if not options.has_key( '--results-prefix' ): if options.has_key( '--v2' ): options[ '--results-prefix' ] = 'all' else: options[ '--results-prefix' ] = '' return ( options[ '--locate-root' ] , options[ '--tag' ] , options[ '--expected-results' ] , options[ '--failures-markup' ] , options[ '--comment' ] , options[ '--results-dir' ] , options[ '--results-prefix' ] , options.has_key( '--dont-collect-logs' ) , options[ '--reports' ].split( ',' ) , options.has_key( '--v2' ) , options[ '--user' ] , options.has_key( '--upload' ) )