1
0
mirror of https://gitlab.com/libvirt/libvirt-python.git synced 2025-03-11 16:58:17 +03:00

test_api_coverage: Reflect different naming in python for virDomainFDAssociate() and virDomainRestoreParams()

While virDomainRestoreParams() has 'virDomain' prefix (and thus
is put into Domain class), it is really in the same family as
virDomainRestore() or virDomainRestoreFlags() -> it acts upon
virConnect object and thus belongs into Connect class.

Then, virDomainFDAssociate is exposed as Domain.FDAssociate() but
because of the way we would generate the method's name
(fDAssociate) the test thinks it's not implemented.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
Michal Privoznik 2024-02-27 14:51:59 +01:00
parent 56179c6a50
commit 426a7689a7

View File

@ -246,7 +246,7 @@ def fixup_class_method_mapping(basicklassmap):
"LookupByID", "LookupByName", "LookupByKey", "LookupByPath",
"LookupByMACString", "LookupByUsage", "LookupByVolume",
"LookupByTargetPath", "LookupSCSIHostByWWN", "LookupByPortDev",
"Restore", "RestoreFlags",
"Restore", "RestoreFlags", "RestoreParams",
"SaveImageDefineXML", "SaveImageGetXMLDesc", "DefineXMLFlags",
"CreateXMLFlags"]:
if klass != "virDomain":
@ -317,6 +317,8 @@ def fixup_class_method_mapping(basicklassmap):
func = "XMLDesc"
if func == "mACString":
func = "MACString"
if func == "fDAssociate":
func = "FDAssociate"
finalklassmap[name] = (klass, func, cname)