Subject: tests: cli: Adjust hotplug test for latest libvirt From: Cole Robinson crobinso@redhat.com Mon Jan 22 17:10:41 2024 -0500 Date: Mon Jan 22 17:10:41 2024 -0500: Git: 83fcc5b2e8f2cede84564387756fe8971de72188 The libvirt test driver now has implementations for hotplug routines, which broke string matching for one case. Loosen it up to work for old and new libvirt versions. Signed-off-by: Cole Robinson --- a/tests/test_cli.py +++ b/tests/test_cli.py @@ -1334,7 +1334,7 @@ c.add_invalid("test --edit --cpu host-pa c.add_invalid("test --edit", grep="No change specified.") c.add_invalid("test --edit 2 --cpu host-passthrough", grep="'--edit 2' requested but there's only 1 --cpu object in the XML") c.add_invalid("test-for-virtxml --edit 5 --tpm /dev/tpm", grep="'--edit 5' requested but there's only 1 --tpm object in the XML") -c.add_invalid("test-for-virtxml --add-device --host-device 0x04b3:0x4485 --update --confirm", input_text="yes", grep="not supported by the connection driver: virDomainAttachDevice") +c.add_invalid("test-for-virtxml --add-device --host-device 0x04b3:0x4485 --update --confirm", input_text="yes", grep="not supported") c.add_invalid("test-for-virtxml --remove-device --host-device 1 --update --confirm", input_text="foo\nyes\n", grep="not supported by the connection driver: virDomainDetachDevice") c.add_invalid("test-for-virtxml --edit --graphics password=foo,keymap= --update --confirm", input_text="yes", grep="not supported by the connection driver: virDomainUpdateDeviceFlags") c.add_invalid("--build-xml --memory 10,maxmemory=20", grep="--build-xml not supported for --memory")