xref: /qemu/tests/functional/test_arm_vexpress.py (revision c3cff7279a462dc3d16bd64524a597ce79214cfa)
1*c3cff727SThomas Huth#!/usr/bin/env python3
2*c3cff727SThomas Huth#
3*c3cff727SThomas Huth# Functional test that boots a Linux kernel on an versatile express machine
4*c3cff727SThomas Huth# and checks the console
5*c3cff727SThomas Huth#
6*c3cff727SThomas Huth# SPDX-License-Identifier: GPL-2.0-or-later
7*c3cff727SThomas Huth
8*c3cff727SThomas Huthfrom qemu_test import LinuxKernelTest, Asset
9*c3cff727SThomas Huthfrom qemu_test.utils import archive_extract
10*c3cff727SThomas Huth
11*c3cff727SThomas Huthclass VExpressTest(LinuxKernelTest):
12*c3cff727SThomas Huth
13*c3cff727SThomas Huth    ASSET_DAY16 = Asset(
14*c3cff727SThomas Huth        'https://www.qemu-advent-calendar.org/2018/download/day16.tar.xz',
15*c3cff727SThomas Huth        '63311adb2d4c4e7a73214a86d29988add87266a909719c56acfadd026b4110a7')
16*c3cff727SThomas Huth
17*c3cff727SThomas Huth    def test_arm_vexpressa9(self):
18*c3cff727SThomas Huth        self.set_machine('vexpress-a9')
19*c3cff727SThomas Huth        file_path = self.ASSET_DAY16.fetch()
20*c3cff727SThomas Huth        archive_extract(file_path, self.workdir)
21*c3cff727SThomas Huth        self.launch_kernel(self.workdir + '/day16/winter.zImage',
22*c3cff727SThomas Huth                           dtb=self.workdir + '/day16/vexpress-v2p-ca9.dtb',
23*c3cff727SThomas Huth                           wait_for='QEMU advent calendar')
24*c3cff727SThomas Huth
25*c3cff727SThomas Huthif __name__ == '__main__':
26*c3cff727SThomas Huth    LinuxKernelTest.main()
27