mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 09:10:36 +00:00
validate:launcher: Never try to load a testsuite with the same name from different locations
This commit is contained in:
parent
688265f1a0
commit
48e007cb29
1 changed files with 7 additions and 3 deletions
|
@ -1664,7 +1664,7 @@ class _TestsLauncher(Loggable):
|
|||
return (None, exceptions)
|
||||
|
||||
def _load_testsuites(self):
|
||||
testsuites = set()
|
||||
testsuites = {}
|
||||
for testsuite in self.options.testsuites:
|
||||
if testsuite.endswith('.py') and os.path.exists(testsuite):
|
||||
testsuite = os.path.abspath(os.path.expanduser(testsuite))
|
||||
|
@ -1686,13 +1686,17 @@ class _TestsLauncher(Loggable):
|
|||
testsuite, loaded_module[1]), Colors.FAIL)
|
||||
continue
|
||||
|
||||
testsuites.add(module)
|
||||
if module.__name__ in testsuites:
|
||||
self.info("Trying to load testsuite '%s' a second time?", module.__name__)
|
||||
continue
|
||||
|
||||
testsuites[module.__name__] = module
|
||||
if not hasattr(module, "TEST_MANAGER"):
|
||||
module.TEST_MANAGER = [tester.name for tester in self.testers]
|
||||
elif not isinstance(module.TEST_MANAGER, list):
|
||||
module.TEST_MANAGER = [module.TEST_MANAGER]
|
||||
|
||||
self.options.testsuites = list(testsuites)
|
||||
self.options.testsuites = list(testsuites.values())
|
||||
|
||||
def _setup_testsuites(self):
|
||||
for testsuite in self.options.testsuites:
|
||||
|
|
Loading…
Reference in a new issue