tests: skip img converter test if qubes-img-converter is not installed

This commit is contained in:
Marek Marczykowski-Górecki 2018-10-16 22:13:27 +02:00
parent e2d7f08d42
commit 0255f4d843
No known key found for this signature in database
GPG Key ID: 063938BA42CFA724

View File

@ -74,6 +74,8 @@ class TC_00_ImgConverter(qubes.tests.extra.ExtraTestCase):
p = self.vm.run('qvm-convert-img test.png trusted.png 2>&1',
passio_popen=True)
(stdout, _) = p.communicate()
if p.returncode == 127:
self.skipTest('qubes-img-converter not installed')
self.assertEquals(p.returncode, 0, 'qvm-convert-img failed: {}'.format(
stdout))
self.assertCorrectlyTransformed('test.png', 'trusted.png')