tests: skip disabled_algorithms test when apksigner is present

apksigner doesn't treat MD5 signatures as deprecated, so that portion of
the tests would always fail.
This commit is contained in:
Hans-Christoph Steiner 2019-07-04 00:13:41 +02:00
parent a9aa8788e0
commit a248a69692
1 changed files with 4 additions and 0 deletions

View File

@ -625,6 +625,10 @@ class UpdateTest(unittest.TestCase):
self.assertFalse(os.path.exists(os.path.join('archive', apkName)))
self.assertTrue(os.path.exists(os.path.join('repo', apkName)))
if os.path.exists('/usr/bin/apksigner') or 'apksigner' in config:
print('SKIPPING: apksigner installed and it allows MD5 signatures')
return
javac = config['jarsigner'].replace('jarsigner', 'javac')
v = subprocess.check_output([javac, '-version'], stderr=subprocess.STDOUT)[6:-1].decode('utf-8')
if LooseVersion(v) < LooseVersion('1.8.0_132'):