Author: vharron Date: Fri May 22 14:49:23 2015 New Revision: 238043 URL: http://llvm.org/viewvc/llvm-project?rev=238043&view=rev Log: dotest.py - fixed a bug displaying usage
./dotest.py --help Modified: lldb/trunk/test/dosep.py lldb/trunk/test/dotest.py lldb/trunk/test/dotest_args.py Modified: lldb/trunk/test/dosep.py URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/dosep.py?rev=238043&r1=238042&r2=238043&view=diff ============================================================================== --- lldb/trunk/test/dosep.py (original) +++ lldb/trunk/test/dosep.py Fri May 22 14:49:23 2015 @@ -233,7 +233,10 @@ Run lldb test suite using a separate pro is_posix = (os.name == "posix") dotest_argv = shlex.split(dotest_option_string, posix=is_posix) if dotest_option_string else [] - dotest_options = dotest_args.getArguments(dotest_argv) + + parser = dotest_args.create_parser() + dotest_options = dotest_args.parse_args(parser, dotest_argv) + if not dotest_options.s: # no session log directory, we need to add this to prevent # every dotest invocation from creating its own directory Modified: lldb/trunk/test/dotest.py URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/dotest.py?rev=238043&r1=238042&r2=238043&view=diff ============================================================================== --- lldb/trunk/test/dotest.py (original) +++ lldb/trunk/test/dotest.py Fri May 22 14:49:23 2015 @@ -491,7 +491,8 @@ def parseOptionsAndInitTestdirs(): platform_system = platform.system() platform_machine = platform.machine() - args = dotest_args.getArguments(sys.argv[1:]) + parser = dotest_args.create_parser() + args = dotest_args.parse_args(parser, sys.argv[1:]) if args.unset_env_varnames: for env_var in args.unset_env_varnames: Modified: lldb/trunk/test/dotest_args.py URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/dotest_args.py?rev=238043&r1=238042&r2=238043&view=diff ============================================================================== --- lldb/trunk/test/dotest_args.py (original) +++ lldb/trunk/test/dotest_args.py Fri May 22 14:49:23 2015 @@ -26,8 +26,7 @@ def parse_args(parser, argv): else: return parser.parse_args(args=argv) -def getArguments(argv): - +def create_parser(): parser = argparse.ArgumentParser(description='description', prefix_chars='+-', add_help=False) group = None @@ -114,4 +113,4 @@ def getArguments(argv): group = parser.add_argument_group('Test directories') group.add_argument('args', metavar='test-dir', nargs='*', help='Specify a list of directory names to search for test modules named after Test*.py (test discovery). If empty, search from the current working directory instead.') - return parse_args(parser, argv) + return parser _______________________________________________ lldb-commits mailing list lldb-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits