1#!/usr/bin/env python3 2# 3# Functional test that boots a Linux kernel on an MCF5208EVB machine 4# and checks the console 5# 6# SPDX-License-Identifier: GPL-2.0-or-later 7 8import os 9 10from qemu_test import LinuxKernelTest, Asset 11from qemu_test.utils import archive_extract 12 13class Mcf5208EvbTest(LinuxKernelTest): 14 15 ASSET_DAY07 = Asset( 16 'https://qemu-advcal.gitlab.io/qac-best-of-multiarch/download/day07.tar.xz', 17 '753c2f3837126b7c6ba92d0b1e0b156e8a2c5131d2d576bb0b9a763fae73c08a') 18 19 def test_m68k_mcf5208evb(self): 20 self.set_machine('mcf5208evb') 21 file_path = self.ASSET_DAY07.fetch() 22 archive_extract(file_path, self.workdir) 23 self.vm.set_console() 24 self.vm.add_args('-kernel', self.workdir + '/day07/sanity-clause.elf') 25 self.vm.launch() 26 self.wait_for_console_pattern('QEMU advent calendar') 27 28if __name__ == '__main__': 29 LinuxKernelTest.main() 30