diff options
| author | Thomas Huth <thuth@redhat.com> | 2025-09-30 11:04:44 +0200 |
|---|---|---|
| committer | Fabiano Rosas <farosas@suse.de> | 2025-10-01 17:09:21 -0300 |
| commit | 030cd885563e9ca843a46ec7e65b657c93df5af7 (patch) | |
| tree | 0a71407bf2c22da76bdefa48f2a7e73f3a6b66d3 /tests/qtest/bios-tables-test.c | |
| parent | 29b77c1a2db2d796bc3847852a5c8dc2a1e6e83b (diff) | |
| download | focaccia-qemu-030cd885563e9ca843a46ec7e65b657c93df5af7.tar.gz focaccia-qemu-030cd885563e9ca843a46ec7e65b657c93df5af7.zip | |
tests/qtest: Add missing checks for the availability of machines
When QEMU has been compiled with "--without-default-devices", the machines might not be available in the binary. Let's properly check for the machines before running the tests to avoid that they are failing in this case. Signed-off-by: Thomas Huth <thuth@redhat.com> Link: https://lore.kernel.org/qemu-devel/20250930090444.234431-1-thuth@redhat.com Signed-off-by: Fabiano Rosas <farosas@suse.de>
Diffstat (limited to 'tests/qtest/bios-tables-test.c')
| -rw-r--r-- | tests/qtest/bios-tables-test.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/qtest/bios-tables-test.c b/tests/qtest/bios-tables-test.c index 4fa8ac5096..6b892ef23e 100644 --- a/tests/qtest/bios-tables-test.c +++ b/tests/qtest/bios-tables-test.c @@ -2864,7 +2864,7 @@ int main(int argc, char *argv[]) test_acpi_riscv64_virt_tcg_acpi_spcr); } } else if (strcmp(arch, "loongarch64") == 0) { - if (has_tcg) { + if (has_tcg && qtest_has_machine("virt")) { qtest_add_func("acpi/virt", test_acpi_loongarch64_virt); qtest_add_func("acpi/virt/topology", test_acpi_loongarch64_virt_topology); |