selftest: Add --filtered-subunit option.
authorJelmer Vernooij <jelmer@samba.org>
Thu, 8 Apr 2010 14:48:33 +0000 (16:48 +0200)
committerJelmer Vernooij <jelmer@samba.org>
Thu, 8 Apr 2010 21:20:35 +0000 (23:20 +0200)
source4/selftest/wscript

index 620f223afd1d947d027b45364507d3d8a43f1a8a..e1d07d5093527bc1b23cb75b7fe2783b46fa1179 100644 (file)
@@ -24,6 +24,9 @@ def set_options(opt):
     gr.add_option('--tests',
                   help=("wildcard pattern of tests to run"),
                   action="store", dest='TESTS', default='')
+    gr.add_option('--filtered-subunit',
+                  help=("output (xfail) filtered subunit"),
+                  action="store_true", dest='FILTERED_SUBUNIT', default=False)
     gr.add_option('--quick',
                   help=("enable only quick tests"),
                   action="store_true", dest='QUICKTEST', default=False)
@@ -74,7 +77,9 @@ def cmd_testonly(opt):
     if os.environ.get('RUN_FROM_BUILD_FARM') is not None:
         env.FILTER_OPTIONS = '${FILTER_XFAIL} --strip-passed-output'
     else:
-        env.FILTER_OPTIONS = '${FILTER_XFAIL} | ${FORMAT_TEST_OUTPUT}'
+        env.FILTER_OPTIONS = '${FILTER_XFAIL}'
+        if not Options.options.FILTERED_SUBUNIT:
+            env.FILTER_OPTIONS += ' | ${FORMAT_TEST_OUTPUT}'
 
     if Options.options.VALGRIND:
         os.environ['VALGRIND'] = 'valgrind -q --num-callers=30'