]> Git Repo - J-u-boot.git/blob - test/py/tests/test_qfw.py
Merge tag 'u-boot-imx-master-20250127' of https://gitlab.denx.de/u-boot/custodians...
[J-u-boot.git] / test / py / tests / test_qfw.py
1 # SPDX-License-Identifier: GPL-2.0+
2 # Copyright (c) 2021, Asherah Connor <[email protected]>
3
4 # Test qfw command implementation
5
6 import pytest
7
8 @pytest.mark.buildconfigspec('cmd_qfw')
9 def test_qfw_cpus(u_boot_console):
10     "Test QEMU firmware config reports the CPU count."
11
12     output = u_boot_console.run_command('qfw cpus')
13     # The actual number varies depending on the board under test, so only
14     # assert a non-zero output.
15     assert 'cpu(s) online' in output
16     assert '0 cpu(s) online' not in output
17
18 @pytest.mark.buildconfigspec('cmd_qfw')
19 def test_qfw_list(u_boot_console):
20     "Test QEMU firmware config lists devices."
21
22     output = u_boot_console.run_command('qfw list')
23     # Assert either:
24     # 1) 'test-one', from the sandbox driver, or
25     # 2) 'bootorder', found in every real QEMU implementation.
26     assert ("bootorder" in output) or ("test-one" in output)
This page took 0.024832 seconds and 4 git commands to generate.