validate:launcher: Make it possible to run any scenario test in gst-validate

This commit is contained in:
Thibault Saunier 2014-04-25 11:32:04 +02:00
parent 8035094128
commit 8b4542540c
2 changed files with 9 additions and 0 deletions

View file

@ -318,6 +318,7 @@ class GstValidateManager(TestsManager, Loggable):
TestsManager.__init__(self)
Loggable.__init__(self)
self._uris = []
self._run_defaults = True
def init(self):
if which(GST_VALIDATE_COMMAND) and which(GST_VALIDATE_TRANSCODING_COMMAND):
@ -489,3 +490,8 @@ class GstValidateManager(TestsManager, Loggable):
def get_blacklisted(self):
return G_V_BLACKLISTED_TESTS
def set_settings(self, options, args, reporter):
TestsManager.set_settings(self, options, args, reporter)
if options.wanted_tests:
self._run_defaults = False

View file

@ -709,6 +709,9 @@ class ScenarioManager(Loggable):
if self.discovered is False:
self._discover_scenarios()
if name is None:
return self.all_scenarios
try:
return [scenario for scenario in self.all_scenarios if scenario.name == name][0]
except IndexError: