[libvirt] [PATCH] qemuxmlnstest: Remove migrate{From,Fd}

They are unused and make no sense in this test. It was most likely a result of copy&paste from another test. Signed-off-by: Jiri Denemark <jdenemar@redhat.com> --- tests/qemuxmlnstest.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/tests/qemuxmlnstest.c b/tests/qemuxmlnstest.c index 4d83f7a..6ca7847 100644 --- a/tests/qemuxmlnstest.c +++ b/tests/qemuxmlnstest.c @@ -30,8 +30,6 @@ static virQEMUDriver driver; static int testCompareXMLToArgvFiles(const char *xml, const char *cmdline, virQEMUCapsPtr extraFlags, - const char *migrateFrom, - int migrateFd, bool json, bool expectError) { @@ -106,7 +104,7 @@ static int testCompareXMLToArgvFiles(const char *xml, if (!(cmd = qemuBuildCommandLine(conn, &driver, vmdef, monitor_chr, json, extraFlags, - migrateFrom, migrateFd, NULL, + NULL, -1, NULL, VIR_NETDEV_VPORT_PROFILE_OP_NO_OP, &testCallbacks, false, false, NULL, NULL, NULL))) @@ -157,8 +155,6 @@ static int testCompareXMLToArgvFiles(const char *xml, struct testInfo { const char *name; virQEMUCapsPtr extraFlags; - const char *migrateFrom; - int migrateFd; bool json; bool expectError; }; @@ -184,7 +180,6 @@ testCompareXMLToArgvHelper(const void *data) goto cleanup; result = testCompareXMLToArgvFiles(xml, args, info->extraFlags, - info->migrateFrom, info->migrateFd, info->json, info->expectError); cleanup: @@ -212,10 +207,10 @@ mymain(void) if (VIR_STRDUP_QUIET(driver.config->libDir, "/tmp") < 0) return EXIT_FAILURE; -# define DO_TEST_FULL(name, migrateFrom, migrateFd, expectError, ...) \ +# define DO_TEST(name, expectError, ...) \ do { \ struct testInfo info = { \ - name, NULL, migrateFrom, migrateFd, json, expectError \ + name, NULL, json, expectError \ }; \ if (!(info.extraFlags = virQEMUCapsNew())) \ return EXIT_FAILURE; \ @@ -226,9 +221,6 @@ mymain(void) virObjectUnref(info.extraFlags); \ } while (0) -# define DO_TEST(name, expectError, ...) \ - DO_TEST_FULL(name, NULL, -1, expectError, __VA_ARGS__) - # define NONE QEMU_CAPS_LAST /* Unset or set all envvars here that are copied in qemudBuildCommandLine -- 2.6.3

On Wed, Nov 11, 2015 at 03:37:23PM +0100, Jiri Denemark wrote:
They are unused and make no sense in this test. It was most likely a result of copy&paste from another test.
Signed-off-by: Jiri Denemark <jdenemar@redhat.com> --- tests/qemuxmlnstest.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-)
I've long wondered why we even have qemuxmlnstest.c ? It seems it could be folded into qemuxml2argvtest.c Regards, Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|

On Wed, Nov 11, 2015 at 14:40:40 +0000, Daniel P. Berrange wrote:
On Wed, Nov 11, 2015 at 03:37:23PM +0100, Jiri Denemark wrote:
They are unused and make no sense in this test. It was most likely a result of copy&paste from another test.
Signed-off-by: Jiri Denemark <jdenemar@redhat.com> --- tests/qemuxmlnstest.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-)
I've long wondered why we even have qemuxmlnstest.c ? It seems it could be folded into qemuxml2argvtest.c
Hmm, I somehow thought we were doing something clever in that test, but looking at it now we don't :-) I'll just move the tests to xml2argv test then. Jirka
participants (2)
-
Daniel P. Berrange
-
Jiri Denemark