summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Fiselier <eric@efcs.ca>2014-08-02 01:29:52 +0000
committerEric Fiselier <eric@efcs.ca>2014-08-02 01:29:52 +0000
commitc85f00a0622d7e49e9ac8a6612e0fd23a0417bd5 (patch)
treecd96992d6f7ae66990d819263eeda97c00e6e59b
parenta80c8770f9506277cd4768fdddda0b78444b6ab2 (diff)
downloadbcm5719-llvm-c85f00a0622d7e49e9ac8a6612e0fd23a0417bd5.tar.gz
bcm5719-llvm-c85f00a0622d7e49e9ac8a6612e0fd23a0417bd5.zip
[lit] Add --show-xfail flag to LIT.
Summary: This patch add a --show-xfail flag. If this flag is specified then each xfail test will be printed to output. When it is not given xfail tests are ignored. Ignoring xfail tests is the current behavior. This flag is meant to mirror the --show-unsupported flag that was recently added. Reviewers: ddunbar, EricWF Reviewed By: EricWF Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D4750 llvm-svn: 214609
-rw-r--r--llvm/docs/CommandGuide/lit.rst4
-rwxr-xr-xllvm/utils/lit/lit/main.py4
2 files changed, 8 insertions, 0 deletions
diff --git a/llvm/docs/CommandGuide/lit.rst b/llvm/docs/CommandGuide/lit.rst
index de7fefff300..ffb4abd3922 100644
--- a/llvm/docs/CommandGuide/lit.rst
+++ b/llvm/docs/CommandGuide/lit.rst
@@ -88,6 +88,10 @@ OUTPUT OPTIONS
Show the names of unsupported tests.
+.. option:: --show-xfail
+
+ Show the names of tests that were expected to fail.
+
.. _execution-options:
EXECUTION OPTIONS
diff --git a/llvm/utils/lit/lit/main.py b/llvm/utils/lit/lit/main.py
index 1f62e3563e8..2ec14e5e5df 100755
--- a/llvm/utils/lit/lit/main.py
+++ b/llvm/utils/lit/lit/main.py
@@ -44,6 +44,7 @@ class TestingProgressDisplay(object):
shouldShow = test.result.code.isFailure or \
(self.opts.show_unsupported and test.result.code.name == 'UNSUPPORTED') or \
+ (self.opts.show_xfail and test.result.code.name == 'XFAIL') or \
(not self.opts.quiet and not self.opts.succinct)
if not shouldShow:
return
@@ -173,6 +174,9 @@ def main(builtinParameters = {}):
group.add_option("", "--show-unsupported", dest="show_unsupported",
help="Show unsupported tests",
action="store_true", default=False)
+ group.add_option("", "--show-xfail", dest="show_xfail",
+ help="Show tests that were expected to fail",
+ action="store_true", default=False)
parser.add_option_group(group)
group = OptionGroup(parser, "Test Execution")
OpenPOWER on IntegriCloud