aboutsummaryrefslogtreecommitdiff
path: root/piglit-run.py
diff options
context:
space:
mode:
authorCarl Worth <cworth@cworth.org>2010-07-29 09:31:11 -0700
committerCarl Worth <cworth@cworth.org>2010-07-29 09:43:37 -0700
commitccd5cf06bf013bfc23d7da9b2e50e40c6b8f61e5 (patch)
tree88d17fd8f45c48f54cbd0bc0218e0e4a93be8f66 /piglit-run.py
parent25d9e7db06d8b9efb4dc6806258b660eb06e4407 (diff)
downloadpiglit-ccd5cf06bf013bfc23d7da9b2e50e40c6b8f61e5.tar.gz
Add -x|--exclude-tests= option to specify tests not to run.
This is a blacklist to complement the existing -t|--tests whitelist. It works similarly, (accepts a regular expression and can be specified multiple times).
Diffstat (limited to 'piglit-run.py')
-rwxr-xr-xpiglit-run.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/piglit-run.py b/piglit-run.py
index 20f7c3a2..9f0eca67 100755
--- a/piglit-run.py
+++ b/piglit-run.py
@@ -42,6 +42,8 @@ Options:
-d, --dry-run Do not execute the tests
-t regexp, --tests=regexp Run only matching tests (can be used more
than once)
+ -x regexp, --exclude-tests=regexp Excludey matching tests (can be used
+ more than once)
-n name, --name=name Name of the testrun
Example:
@@ -62,7 +64,7 @@ def main():
env = core.Environment()
try:
- options, args = getopt(sys.argv[1:], "hdt:n:", [ "help", "dry-run", "tests=", "name=" ])
+ options, args = getopt(sys.argv[1:], "hdt:n:x:", [ "help", "dry-run", "tests=", "name=", "exclude-tests=" ])
except GetoptError:
usage()
@@ -75,6 +77,8 @@ def main():
env.execute = False
elif name in ('-t', '--tests'):
env.filter[:0] = [re.compile(value)]
+ elif name in ('-x', '--exclude-tests'):
+ env.exclude_filter[:0] = [re.compile(value)]
elif name in ('-n', '--name'):
OptionName = value