tests: add QUBES_TEST_TEMPLATES env variable
Allow easily list templates to be tested, without enumerating all the test classes. This is especially useful with nose2 runner which can't use load tests protocol _and_ select subset of tests.
This commit is contained in:
parent
35c66987ab
commit
7a607e3731
@ -1143,6 +1143,9 @@ _templates = None
|
||||
def list_templates():
|
||||
'''Returns tuple of template names available in the system.'''
|
||||
global _templates
|
||||
if _templates is None:
|
||||
if 'QUBES_TEST_TEMPLATES' in os.environ:
|
||||
_templates = os.environ['QUBES_TEST_TEMPLATES'].split()
|
||||
if _templates is None:
|
||||
try:
|
||||
app = qubes.Qubes()
|
||||
|
Loading…
Reference in New Issue
Block a user