diff options
| author | Thomas Huth <thuth@redhat.com> | 2024-09-06 20:05:47 +0200 |
|---|---|---|
| committer | Thomas Huth <thuth@redhat.com> | 2024-09-11 09:49:11 +0200 |
| commit | 9a76bc0433cc1de1ab588f9e322aefac40463295 (patch) | |
| tree | 6d616a01f1fa8f230b11123f0672ccf2cecdce68 /tests/functional/test_alpha_clipper.py | |
| parent | 547738be48211ed3b37b13f7a75cca3281b760f5 (diff) | |
| download | focaccia-qemu-9a76bc0433cc1de1ab588f9e322aefac40463295.tar.gz focaccia-qemu-9a76bc0433cc1de1ab588f9e322aefac40463295.zip | |
tests/functional: Convert the Alpha Clipper Avocado test
Straight forward conversion, just switch to SHA256 hashsum now. Tested-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Message-ID: <20240906180549.792832-13-thuth@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
Diffstat (limited to 'tests/functional/test_alpha_clipper.py')
| -rwxr-xr-x | tests/functional/test_alpha_clipper.py | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/tests/functional/test_alpha_clipper.py b/tests/functional/test_alpha_clipper.py new file mode 100755 index 0000000000..c1fbf0e395 --- /dev/null +++ b/tests/functional/test_alpha_clipper.py @@ -0,0 +1,38 @@ +#!/usr/bin/env python3 +# +# Functional test that boots a Linux kernel on an Alpha Clipper machine +# and checks the console +# +# SPDX-License-Identifier: GPL-2.0-or-later + +import os + +from qemu_test import LinuxKernelTest, Asset +from qemu_test.utils import gzip_uncompress + + +class AlphaClipperTest(LinuxKernelTest): + + ASSET_KERNEL = Asset( + ('http://archive.debian.org/debian/dists/lenny/main/' + 'installer-alpha/20090123lenny10/images/cdrom/vmlinuz'), + '34f53da3fa32212e4f00b03cb944b2ad81c06bc8faaf9b7193b2e544ceeca576') + + def test_alpha_clipper(self): + self.set_machine('clipper') + kernel_path = self.ASSET_KERNEL.fetch() + + uncompressed_kernel = os.path.join(self.workdir, 'vmlinux') + gzip_uncompress(kernel_path, uncompressed_kernel) + + self.vm.set_console() + kernel_command_line = self.KERNEL_COMMON_COMMAND_LINE + 'console=ttyS0' + self.vm.add_args('-nodefaults', + '-kernel', uncompressed_kernel, + '-append', kernel_command_line) + self.vm.launch() + console_pattern = 'Kernel command line: %s' % kernel_command_line + self.wait_for_console_pattern(console_pattern) + +if __name__ == '__main__': + LinuxKernelTest.main() |