From: Peter Krempa <[email protected]> The tests now use 'testQemuPrepareHostBackendChardevOne' which replaces 'qemuProcessPrepareHostBackendChardevOne' which is skipped as it is a host setup step.
Signed-off-by: Peter Krempa <[email protected]> --- src/qemu/qemu_command.h | 3 +-- tests/qemuxml2argvmock.c | 17 ----------------- 2 files changed, 1 insertion(+), 19 deletions(-) diff --git a/src/qemu/qemu_command.h b/src/qemu/qemu_command.h index 028d002ef9..e34172fbff 100644 --- a/src/qemu/qemu_command.h +++ b/src/qemu/qemu_command.h @@ -74,8 +74,7 @@ qemuBuildTLSx509BackendProps(const char *tlspath, /* Open a UNIX socket for chardev FD passing */ int -qemuOpenChrChardevUNIXSocket(const virDomainChrSourceDef *dev) - ATTRIBUTE_MOCKABLE; +qemuOpenChrChardevUNIXSocket(const virDomainChrSourceDef *dev); virJSONValue * qemuBuildChrDeviceProps(const virDomainDef *vmdef, diff --git a/tests/qemuxml2argvmock.c b/tests/qemuxml2argvmock.c index 9d10b5655f..b4ebf1a172 100644 --- a/tests/qemuxml2argvmock.c +++ b/tests/qemuxml2argvmock.c @@ -236,23 +236,6 @@ qemuInterfaceOpenVhostNet(virDomainObj *vm G_GNUC_UNUSED, } -int -qemuOpenChrChardevUNIXSocket(const virDomainChrSourceDef *dev G_GNUC_UNUSED) - -{ - /* We need to return an FD number for a UNIX listener socket, - * which will be given to QEMU via a CLI arg. We need a fixed - * number to get stable tests. This is obviously not a real - * FD number, so when virCommand closes the FD in the parent - * it will get EINVAL, but that's (hopefully) not going to - * be a problem.... - */ - if (fcntl(1729, F_GETFD) != -1) - abort(); - return 1729; -} - - int qemuBuildTPMOpenBackendFDs(const char *tpmdev G_GNUC_UNUSED, int *tpmfd, -- 2.54.0
