[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 11/16] tests/acceptance/boot_xen.py: fetch kernel during test set
From: |
Cleber Rosa |
Subject: |
[PATCH 11/16] tests/acceptance/boot_xen.py: fetch kernel during test setUp() |
Date: |
Fri, 24 Sep 2021 14:55:01 -0400 |
The kernel is a common blob used in all tests. By moving it to the
setUp() method, the "fetch asset" plugin will recognize the kernel and
attempt to fetch it and cache it before the tests are started.
Signed-off-by: Cleber Rosa <crosa@redhat.com>
---
tests/acceptance/boot_xen.py | 13 ++++++-------
1 file changed, 6 insertions(+), 7 deletions(-)
diff --git a/tests/acceptance/boot_xen.py b/tests/acceptance/boot_xen.py
index e2c59f6592..cd916ddba4 100644
--- a/tests/acceptance/boot_xen.py
+++ b/tests/acceptance/boot_xen.py
@@ -31,23 +31,22 @@ class BootXen(LinuxKernelTest):
timeout = 90
XEN_COMMON_COMMAND_LINE = 'dom0_mem=128M loglvl=all guest_loglvl=all'
- def fetch_guest_kernel(self):
+ def setUp(self):
+ super(BootXen, self).setUp()
+
# Using my own built kernel - which works
kernel_url = ('https://fileserver.linaro.org/'
's/JSsewXGZ6mqxPr5/download?path=%2F&files='
'linux-5.9.9-arm64-ajb')
kernel_sha1 = '4f92bc4b9f88d5ab792fa7a43a68555d344e1b83'
- kernel_path = self.fetch_asset(kernel_url,
- asset_hash=kernel_sha1)
-
- return kernel_path
+ self.kernel_path = self.fetch_asset(kernel_url,
+ asset_hash=kernel_sha1)
def launch_xen(self, xen_path):
"""
Launch Xen with a dom0 guest kernel
"""
self.log.info("launch with xen_path: %s", xen_path)
- kernel_path = self.fetch_guest_kernel()
self.vm.set_console()
@@ -58,7 +57,7 @@ def launch_xen(self, xen_path):
'-append', xen_command_line,
'-device',
'guest-loader,addr=0x47000000,kernel=%s,bootargs=console=hvc0'
- % (kernel_path))
+ % (self.kernel_path))
self.vm.launch()
--
2.31.1
- [PATCH 06/16] Acceptance Tests: use extract from package from avocado.utils, (continued)
- [PATCH 06/16] Acceptance Tests: use extract from package from avocado.utils, Cleber Rosa, 2021/09/24
- [PATCH 07/16] Acceptance Tests: workaround expired mipsdistros.mips.com HTTPS cert, Cleber Rosa, 2021/09/24
- [PATCH 08/16] acceptance/tests/vnc.py: use explicit syntax for enabling passwords, Cleber Rosa, 2021/09/24
- [PATCH 09/16] tests/acceptance/boot_xen.py: merge base classes, Cleber Rosa, 2021/09/24
- [PATCH 03/16] Acceptance Tests: add mechanism for listing tests, Cleber Rosa, 2021/09/24
- [PATCH 10/16] tests/acceptance/boot_xen.py: unify tags, Cleber Rosa, 2021/09/24
- [PATCH 02/16] Acceptance Tests: improve check-acceptance description, Cleber Rosa, 2021/09/24
- [PATCH 04/16] Acceptance Tests: keep track and disable tests with known issues, Cleber Rosa, 2021/09/24
- [PATCH 11/16] tests/acceptance/boot_xen.py: fetch kernel during test setUp(),
Cleber Rosa <=
- [PATCH 12/16] tests/acceptance/boot_xen.py: removed unused import, Cleber Rosa, 2021/09/24
- [PATCH 13/16] tests/acceptance/boot_xen.py: use class attribute, Cleber Rosa, 2021/09/24
- [PATCH 14/16] tests/acceptance/ppc_prep_40p.py: NetBSD 7.1.2 location update, Cleber Rosa, 2021/09/24
- [PATCH 15/16] tests/acceptance/ppc_prep_40p.py: clean up unused import, Cleber Rosa, 2021/09/24
- [PATCH 16/16] tests/acceptance/ppc_prep_40p.py: unify tags, Cleber Rosa, 2021/09/24