]> www.infradead.org Git - users/dwmw2/qemu.git/commitdiff
tests/acceptance: Add Test.fetch_asset(cancel_on_missing=True)
authorPhilippe Mathieu-Daudé <philmd@redhat.com>
Wed, 9 Sep 2020 11:27:40 +0000 (12:27 +0100)
committerAlex Bennée <alex.bennee@linaro.org>
Thu, 10 Sep 2020 09:46:57 +0000 (10:46 +0100)
Invert the default of avocado.Test.fetch_asset 'cancel_on_missing'
keyword: accept missing artefacts by default. If a test is certain
an artifact can't be missing, it will set cancel_on_missing=False.

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20200908202352.298506-3-philmd@redhat.com>
Message-Id: <20200909112742.25730-10-alex.bennee@linaro.org>

tests/acceptance/avocado_qemu/__init__.py

index db9c0f5d79d2735e882a5eb9edd8a9ffc491942e..4cda03718792b7dc263a9c743b5ffab29c336cd3 100644 (file)
@@ -192,3 +192,15 @@ class Test(avocado.Test):
     def tearDown(self):
         for vm in self._vms.values():
             vm.shutdown()
+
+    def fetch_asset(self, name,
+                    asset_hash=None, algorithm=None,
+                    locations=None, expire=None,
+                    find_only=False, cancel_on_missing=True):
+        return super(Test, self).fetch_asset(name,
+                        asset_hash=asset_hash,
+                        algorithm=algorithm,
+                        locations=locations,
+                        expire=expire,
+                        find_only=find_only,
+                        cancel_on_missing=cancel_on_missing)