Add -F to suppress everything that isn't a failure/error.
[third_party/subunit] / filters / subunit-filter
index 567999cadb07d4025dc4cc425ac98b5dd755cd2b..3cd1512c11bd3facf9b0c59f0aece777e89402b0 100755 (executable)
@@ -69,8 +69,20 @@ parser.add_option("--fixup-expected-failures", type=str,
 parser.add_option("--without", type=str,
     help="regexp to exclude (case-sensitive by default)",
     action="append", dest="without_regexps")
+# TODO: This could be done as a callback to allow following options to override
+# parts. As is, we just use it as a big hammer...
+parser.add_option("-F", "--only-genuine-failures", action="store_true",
+    default=False,
+    help="Only pass through failures and exceptions.")
 
 (options, args) = parser.parse_args()
+if options.only_genuine_failures:
+    options.success = True
+    options.skip = True
+    options.xfail = True
+    options.no_passthrough = True
+    # options.error = False
+    # options.failures = False
 
 
 def _compile_re_from_list(l):