tests: storagepoolxml2argvtest: Use integrated command path stripping

Replace virTestClearCommandPath by virCommandToStringFull which allows
to strip the command prefix internally.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
This commit is contained in:
Peter Krempa 2021-04-06 18:38:57 +02:00
parent 2116063791
commit 070cc66d16

View File

@ -74,12 +74,11 @@ testCompareXMLToArgvFiles(bool shouldFail,
goto cleanup;
};
if (!(actualCmdline = virCommandToString(cmd, false))) {
if (!(actualCmdline = virCommandToStringFull(cmd, false, true))) {
VIR_TEST_DEBUG("pool type '%s' failed to get commandline", defTypeStr);
goto cleanup;
}
virTestClearCommandPath(actualCmdline);
if (virTestCompareToFile(actualCmdline, cmdline) < 0)
goto cleanup;