mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-07-29 01:35:06 +00:00
TestsManager: _add_blacklist in set_default_blacklist
Otherwise test suites that want to set_default_blacklist and add tests in setup_tests were seeing their blacklist ignored. Split up and rename set_blacklists() to complete the refactoring
This commit is contained in:
parent
61d0605852
commit
96361bd426
|
@ -1414,6 +1414,7 @@ class TestsManager(Loggable):
|
||||||
if not test_regex.startswith(self.loading_testsuite + '.'):
|
if not test_regex.startswith(self.loading_testsuite + '.'):
|
||||||
test_regex = self.loading_testsuite + '.' + test_regex
|
test_regex = self.loading_testsuite + '.' + test_regex
|
||||||
self.blacklisted_tests.append((test_regex, reason))
|
self.blacklisted_tests.append((test_regex, reason))
|
||||||
|
self._add_blacklist(test_regex)
|
||||||
|
|
||||||
def add_options(self, parser):
|
def add_options(self, parser):
|
||||||
""" Add more arguments. """
|
""" Add more arguments. """
|
||||||
|
@ -1439,22 +1440,22 @@ class TestsManager(Loggable):
|
||||||
for patterns in options.blacklisted_tests:
|
for patterns in options.blacklisted_tests:
|
||||||
self._add_blacklist(patterns)
|
self._add_blacklist(patterns)
|
||||||
|
|
||||||
def set_blacklists(self):
|
def check_blacklists(self):
|
||||||
if self.blacklisted_tests:
|
|
||||||
self.info("Currently 'hardcoded' %s blacklisted tests:" %
|
|
||||||
self.name)
|
|
||||||
|
|
||||||
if self.options.check_bugs_status:
|
if self.options.check_bugs_status:
|
||||||
if not check_bugs_resolution(self.blacklisted_tests):
|
if not check_bugs_resolution(self.blacklisted_tests):
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
return True
|
||||||
|
|
||||||
|
def log_blacklists(self):
|
||||||
|
if self.blacklisted_tests:
|
||||||
|
self.info("Currently 'hardcoded' %s blacklisted tests:" %
|
||||||
|
self.name)
|
||||||
|
|
||||||
for name, bug in self.blacklisted_tests:
|
for name, bug in self.blacklisted_tests:
|
||||||
self._add_blacklist(name)
|
|
||||||
if not self.options.check_bugs_status:
|
if not self.options.check_bugs_status:
|
||||||
self.info(" + %s --> bug: %s" % (name, bug))
|
self.info(" + %s --> bug: %s" % (name, bug))
|
||||||
|
|
||||||
return True
|
|
||||||
|
|
||||||
def check_expected_issues(self):
|
def check_expected_issues(self):
|
||||||
if not self.expected_issues or not self.options.check_bugs_status:
|
if not self.expected_issues or not self.options.check_bugs_status:
|
||||||
return True
|
return True
|
||||||
|
@ -1758,9 +1759,11 @@ class _TestsLauncher(Loggable):
|
||||||
printc("-> Checking bugs resolution... ", end='')
|
printc("-> Checking bugs resolution... ", end='')
|
||||||
|
|
||||||
for tester in self.testers:
|
for tester in self.testers:
|
||||||
if not tester.set_blacklists():
|
if not tester.check_blacklists():
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
tester.log_blacklists()
|
||||||
|
|
||||||
if not tester.check_expected_issues():
|
if not tester.check_expected_issues():
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue