diff --git a/libvirt/tests/cfg/svirt/dac/dac_seclabel_per_device.cfg b/libvirt/tests/cfg/svirt/dac/dac_seclabel_per_device.cfg index 5a86e13f3c..f9b61bbbf4 100644 --- a/libvirt/tests/cfg/svirt/dac/dac_seclabel_per_device.cfg +++ b/libvirt/tests/cfg/svirt/dac/dac_seclabel_per_device.cfg @@ -6,6 +6,8 @@ variants test_scenario: - cold_plug: - hot_plug: + serial: + func_supported_since_libvirt_ver = (8, 7, 0) variants test_device: - disk: disk_attrs_target = {'dev': 'vdb', 'bus': 'virtio'} diff --git a/libvirt/tests/cfg/svirt/selinux/selinux_seclabel_per_device.cfg b/libvirt/tests/cfg/svirt/selinux/selinux_seclabel_per_device.cfg index 0c8dcad58a..fcf65709ae 100644 --- a/libvirt/tests/cfg/svirt/selinux/selinux_seclabel_per_device.cfg +++ b/libvirt/tests/cfg/svirt/selinux/selinux_seclabel_per_device.cfg @@ -6,6 +6,8 @@ variants test_scenario: - cold_plug: - hot_plug: + serial: + func_supported_since_libvirt_ver = (8, 7, 0) variants test_device: - disk: disk_attrs_target = {'dev': 'vdb', 'bus': 'virtio'} diff --git a/libvirt/tests/src/svirt/dac/dac_seclabel_per_device.py b/libvirt/tests/src/svirt/dac/dac_seclabel_per_device.py index 22689e5448..ce7af0f7b3 100644 --- a/libvirt/tests/src/svirt/dac/dac_seclabel_per_device.py +++ b/libvirt/tests/src/svirt/dac/dac_seclabel_per_device.py @@ -4,6 +4,7 @@ from avocado.utils import process from virttest import data_dir +from virttest import libvirt_version from virttest import virsh from virttest.libvirt_xml import xcepts @@ -60,6 +61,8 @@ def run(test, params, env): status_error = 'yes' == params.get("status_error", 'no') + libvirt_version.is_libvirt_feature_supported(params) + dev_dict, seclabel_attr = get_dev_dict(test_device, params) test.log.debug(dev_dict) diff --git a/libvirt/tests/src/svirt/selinux/selinux_seclabel_per_device.py b/libvirt/tests/src/svirt/selinux/selinux_seclabel_per_device.py index 14639dea70..d15ef5dcfa 100644 --- a/libvirt/tests/src/svirt/selinux/selinux_seclabel_per_device.py +++ b/libvirt/tests/src/svirt/selinux/selinux_seclabel_per_device.py @@ -3,6 +3,7 @@ from avocado.utils import process from virttest import data_dir +from virttest import libvirt_version from virttest import virsh from virttest.libvirt_xml import xcepts @@ -58,6 +59,8 @@ def run(test, params, env): vmxml = VMXML.new_from_inactive_dumpxml(vm_name) backup_xml = vmxml.copy() + libvirt_version.is_libvirt_feature_supported(params) + dev_dict, seclabel_attr = get_dev_dict(test_device, params) test.log.debug("The device setting will be updated to %s.", dev_dict) try: