From 611892538736f73e0ee8fca7d89ff9fb19beab5f Mon Sep 17 00:00:00 2001 From: Jochen Sprickerhof Date: Wed, 30 Nov 2022 12:49:21 +0100 Subject: [PATCH] Skip nightly test on Fedora with pip in $HOME --- .gitlab-ci.yml | 1 + tests/nightly.TestCase | 18 ++++++++++++++++-- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9df46726..6376424f 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -274,6 +274,7 @@ fedora_latest: git gnupg java-17-openjdk-devel + openssl python3 python3-babel python3-matplotlib diff --git a/tests/nightly.TestCase b/tests/nightly.TestCase index 8eddc6d7..e7f41a8a 100755 --- a/tests/nightly.TestCase +++ b/tests/nightly.TestCase @@ -246,7 +246,14 @@ class NightlyTest(unittest.TestCase): ): self.assertTrue(self.testroot == Path.home().parent) with patch('subprocess.check_call', _subprocess_check_call): - nightly.main() + try: + nightly.main() + except exception.BuildException as e: + if "apksigner not found" in e.value: + self.skipTest("skipping, apksigner not found due to fake $HOME") + else: + raise + self.assertEqual(called, [['ssh', '-Tvi'], ['fdroid', 'deploy']]) self.assertFalse(os.path.exists('config.py')) git_url = 'git@github.com:f-droid/test-nightly' @@ -314,7 +321,14 @@ class NightlyTest(unittest.TestCase): ): self.assertTrue(self.testroot == Path.home().parent) with patch('subprocess.check_call', _subprocess_check_call): - nightly.main() + try: + nightly.main() + except exception.BuildException as e: + if "apksigner not found" in e.value: + self.skipTest("skipping, apksigner not found due to fake $HOME") + else: + raise + self.assertEqual(called, [['ssh', '-Tvi'], ['fdroid', 'deploy']]) self.assertFalse(os.path.exists('config.py')) expected = {