mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-31 19:42:26 +00:00
validate:launcher: Use a xunit reporter only when explicitely specified
This commit is contained in:
parent
4090b0a7ae
commit
23203ca0bd
3 changed files with 6 additions and 6 deletions
|
@ -1226,7 +1226,10 @@ class _TestsLauncher(Loggable):
|
|||
globals()["__file__"] = c__file__
|
||||
|
||||
def set_settings(self, options, args):
|
||||
self.reporter = reporters.XunitReporter(options)
|
||||
if options.xunit_file:
|
||||
self.reporter = reporters.XunitReporter(options)
|
||||
else:
|
||||
self.reporter = reporters.Reporter(options)
|
||||
|
||||
self.options = options
|
||||
wanted_testers = None
|
||||
|
|
|
@ -251,8 +251,6 @@ class LauncherConfig(Loggable):
|
|||
self.logsdir = None
|
||||
if self.logsdir is None:
|
||||
self.logsdir = os.path.join(self.output_dir, "logs")
|
||||
if self.xunit_file is None:
|
||||
self.xunit_file = os.path.join(self.logsdir, "xunit.xml")
|
||||
if self.dest is None:
|
||||
self.dest = os.path.join(self.output_dir, "rendered")
|
||||
|
||||
|
@ -446,8 +444,7 @@ Note that all testsuite should be inside python modules, so the directory should
|
|||
"Directories and files to be used by the launcher")
|
||||
parser.add_argument('--xunit-file', action='store',
|
||||
dest='xunit_file', metavar="FILE",
|
||||
help=("Path to xml file to store the xunit report in. "
|
||||
"Default is LOGSDIR/xunit.xml"))
|
||||
help=("Path to xml file to store the xunit report in."))
|
||||
dir_group.add_argument("-M", "--main-dir", dest="main_dir",
|
||||
help="Main directory where to put files. Default is %s" % DEFAULT_MAIN_DIR)
|
||||
dir_group.add_argument("--testsuites-dir", dest="testsuites_dir",
|
||||
|
|
|
@ -69,7 +69,7 @@ class Reporter(Loggable):
|
|||
self._start_time = time.time()
|
||||
|
||||
def set_failed(self, test):
|
||||
self.stats["failure"] += 1
|
||||
self.stats["failures"] += 1
|
||||
|
||||
def set_passed(self, test):
|
||||
self.stats["passed"] += 1
|
||||
|
|
Loading…
Reference in a new issue