diff options
Diffstat (limited to 'tests/i440fx-test.c')
-rw-r--r-- | tests/i440fx-test.c | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/tests/i440fx-test.c b/tests/i440fx-test.c index ad232b561c..d0bc8de25a 100644 --- a/tests/i440fx-test.c +++ b/tests/i440fx-test.c @@ -342,8 +342,9 @@ static void test_i440fx_firmware(FirmwareTestFixture *fixture, g_assert(fw_pathname != NULL); /* Better hope the user didn't put metacharacters in TMPDIR and co. */ - cmdline = g_strdup_printf("-S %s %s", - fixture->is_bios ? "-bios" : "-pflash", + cmdline = g_strdup_printf("-S %s%s", fixture->is_bios + ? "-bios " + : "-drive if=pflash,format=raw,file=", fw_pathname); g_test_message("qemu cmdline: %s", cmdline); qtest_start(cmdline); @@ -382,8 +383,8 @@ static void add_firmware_test(const char *testpath, void (*setup_fixture)(FirmwareTestFixture *f, gconstpointer test_data)) { - g_test_add(testpath, FirmwareTestFixture, NULL, setup_fixture, - test_i440fx_firmware, NULL); + qtest_add(testpath, FirmwareTestFixture, NULL, setup_fixture, + test_i440fx_firmware, NULL); } static void request_bios(FirmwareTestFixture *fixture, @@ -407,10 +408,10 @@ int main(int argc, char **argv) data.num_cpus = 1; - g_test_add_data_func("/i440fx/defaults", &data, test_i440fx_defaults); - g_test_add_data_func("/i440fx/pam", &data, test_i440fx_pam); - add_firmware_test("/i440fx/firmware/bios", request_bios); - add_firmware_test("/i440fx/firmware/pflash", request_pflash); + qtest_add_data_func("i440fx/defaults", &data, test_i440fx_defaults); + qtest_add_data_func("i440fx/pam", &data, test_i440fx_pam); + add_firmware_test("i440fx/firmware/bios", request_bios); + add_firmware_test("i440fx/firmware/pflash", request_pflash); ret = g_test_run(); return ret; |