1 # Functional test that boots a Linux kernel and checks the console
3 # Copyright (c) 2020 Red Hat, Inc.
6 # Thomas Huth <thuth@redhat.com>
8 # This work is licensed under the terms of the GNU GPL, version 2 or
9 # later. See the COPYING file in the top-level directory.
13 from avocado
import skipUnless
14 from avocado_qemu
import Test
15 from avocado_qemu
import wait_for_console_pattern
17 class N8x0Machine(Test
):
18 """Boots the Linux kernel and checks that the console is operational"""
22 def __do_test_n8x0(self
):
23 kernel_url
= ('http://stskeeps.subnetmask.net/meego-n8x0/'
24 'meego-arm-n8x0-1.0.80.20100712.1431-'
25 'vmlinuz-2.6.35~rc4-129.1-n8x0')
26 kernel_hash
= 'e9d5ab8d7548923a0061b6fbf601465e479ed269'
27 kernel_path
= self
.fetch_asset(kernel_url
, asset_hash
=kernel_hash
)
29 self
.vm
.set_console(console_index
=1)
30 self
.vm
.add_args('-kernel', kernel_path
,
31 '-append', 'printk.time=0 console=ttyS1')
33 wait_for_console_pattern(self
, 'TSC2005 driver initializing')
35 @skipUnless(os
.getenv('AVOCADO_ALLOW_UNTRUSTED_CODE'), 'untrusted code')
38 :avocado: tags=arch:arm
39 :avocado: tags=machine:n800
43 @skipUnless(os
.getenv('AVOCADO_ALLOW_UNTRUSTED_CODE'), 'untrusted code')
46 :avocado: tags=arch:arm
47 :avocado: tags=machine:n810