diff --git a/lib/hypervisor/hv_kvm.py b/lib/hypervisor/hv_kvm.py index a388ec25424ce43306e87aee1fbfe9db4c49790f..3b2d81ed300fc4f4e954dc15aee771a9b07753d3 100644 --- a/lib/hypervisor/hv_kvm.py +++ b/lib/hypervisor/hv_kvm.py @@ -77,6 +77,9 @@ _SPICE_ADDITIONAL_PARAMS = frozenset([ constants.HV_KVM_SPICE_ZLIB_GLZ_IMG_COMPR, constants.HV_KVM_SPICE_STREAMING_VIDEO_DETECTION, constants.HV_KVM_SPICE_USE_TLS, + constants.HV_KVM_SPICE_AUDIO_COMPR, + constants.HV_KVM_SPICE_TLS_CIPHERS, + constants.HV_KVM_SPICE_USE_VDAGENT, ]) diff --git a/test/ganeti.hypervisor.hv_kvm_unittest.py b/test/ganeti.hypervisor.hv_kvm_unittest.py index 230efffe4ca09621d59ca8375b9dcbd0f9deb139..f401d3351d21b78ad99555abb1f9150f6af8181f 100755 --- a/test/ganeti.hypervisor.hv_kvm_unittest.py +++ b/test/ganeti.hypervisor.hv_kvm_unittest.py @@ -258,5 +258,20 @@ class TestVersionChecking(testutils.GanetiTestCase): self.assertEqual(parse(help_091), ("0.9.1", 0, 9, 1)) +class TestSpiceParameterList(unittest.TestCase): + def test(self): + params = \ + compat.UniqueFrozenset(getattr(constants, name) + for name in dir(constants) + if name.startswith("HV_KVM_SPICE_")) + + # Exclude some parameters + params -= frozenset([ + constants.HV_KVM_SPICE_BIND, + ]) + + self.assertEqual(hv_kvm._SPICE_ADDITIONAL_PARAMS, params) + + if __name__ == "__main__": testutils.GanetiTestProgram()