mirror of
https://gitlab.freedesktop.org/libfprint/libfprint.git
synced 2025-11-15 07:38:12 +00:00
build/tests: Skip a test if the test requires it during inspection
In case we don't have dependencies, we should skip the test, otherwise we can just fail at test time
This commit is contained in:
@@ -100,11 +100,17 @@ if get_option('introspection')
|
|||||||
base_args = files(vdtest + '.py')
|
base_args = files(vdtest + '.py')
|
||||||
suite = ['virtual-driver']
|
suite = ['virtual-driver']
|
||||||
|
|
||||||
r = run_command(unittest_inspector, files(vdtest + '.py'), check: true)
|
r = run_command(unittest_inspector, files(vdtest + '.py'), check: false)
|
||||||
unit_tests = r.stdout().strip().split('\n')
|
unit_tests = r.stdout().strip().split('\n')
|
||||||
|
|
||||||
if r.returncode() == 0 and unit_tests.length() > 0
|
if r.returncode() == 0 and unit_tests.length() > 0
|
||||||
suite += vdtest
|
suite += vdtest
|
||||||
|
elif r.returncode() == 77
|
||||||
|
test(vdtest,
|
||||||
|
sh,
|
||||||
|
args: ['-c', 'exit 77']
|
||||||
|
)
|
||||||
|
continue
|
||||||
else
|
else
|
||||||
unit_tests = [vdtest]
|
unit_tests = [vdtest]
|
||||||
endif
|
endif
|
||||||
|
|||||||
Reference in New Issue
Block a user