[Lldb-commits] [lldb] r170163 - /lldb/trunk/test/dotest.py
Enrico Granata
egranata at apple.com
Thu Dec 13 16:07:09 PST 2012
Author: enrico
Date: Thu Dec 13 18:07:09 2012
New Revision: 170163
URL: http://llvm.org/viewvc/llvm-project?rev=170163&view=rev
Log:
Fixing the -f option so that one specify multiple filters, e.g.
./dotest.py -C clang --arch x86_64 --arch i386 -v -t -f ObjCDataFormatterTestCase.test_appkit_with_dsym_and_run_command -f ObjCDataFormatterTestCase.test_appkit_with_dwarf_and_run_command -f TestObjCBuiltinTypes.test_with_dsym_and_python_api -f TestObjCBuiltinTypes.test_with_dwarf_and_python_api -f ObjCDataFormatterTestCase.test_appkit_with_dsym_and_run_command -f ObjCDataFormatterTestCase.test_appkit_with_dwarf_and_run_command -f TestObjCBuiltinTypes.test_with_dsym_and_python_api -f -TestObjCBuiltinTypes.test_with_dwarf_and_python_api
The previous implementation would only remember the last filter passed, and consequently break redo.py
Modified:
lldb/trunk/test/dotest.py
Modified: lldb/trunk/test/dotest.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/dotest.py?rev=170163&r1=170162&r2=170163&view=diff
==============================================================================
--- lldb/trunk/test/dotest.py (original)
+++ lldb/trunk/test/dotest.py Thu Dec 13 18:07:09 2012
@@ -377,7 +377,7 @@
X('+a', "Just do lldb Python API tests. Do not specify along with '+a'", dest='plus_a')
X('+b', 'Just do benchmark tests', dest='plus_b')
group.add_argument('-b', metavar='blacklist', help='Read a blacklist file specified after this option')
- group.add_argument('-f', metavar='filterspec', help='Specify a filter, which consists of the test class name, a dot, followed by the test method, to only admit such test into the test suite') # FIXME: Example?
+ group.add_argument('-f', metavar='filterspec', action='append', help='Specify a filter, which consists of the test class name, a dot, followed by the test method, to only admit such test into the test suite') # FIXME: Example?
X('-g', 'If specified, the filterspec by -f is not exclusive, i.e., if a test module does not match the filterspec (testclass.testmethod), the whole module is still admitted to the test suite')
X('-l', "Don't skip long running tests")
group.add_argument('-p', metavar='pattern', help='Specify a regexp filename pattern for inclusion in the test suite')
@@ -510,9 +510,9 @@
failfast = True
if args.f:
- if args.f.startswith('-'):
+ if any([x.startswith('-') for x in args.f]):
usage(parser)
- filters.append(args.f)
+ filters.extend(args.f)
if args.g:
fs4all = False
More information about the lldb-commits
mailing list