From e4ca114a1258d4e7352ff3718a0a51d529b5b7fd Mon Sep 17 00:00:00 2001 From: Lili Deng Date: Fri, 20 Oct 2023 11:41:32 +0800 Subject: [PATCH] install needed package for ADE extensions on old distro --- microsoft/testsuites/vm_extensions/azure_disk_encryption.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/microsoft/testsuites/vm_extensions/azure_disk_encryption.py b/microsoft/testsuites/vm_extensions/azure_disk_encryption.py index a78e204d77..4c3c83f7fe 100644 --- a/microsoft/testsuites/vm_extensions/azure_disk_encryption.py +++ b/microsoft/testsuites/vm_extensions/azure_disk_encryption.py @@ -51,6 +51,10 @@ def before_case(self, log: Logger, **kwargs: Any) -> None: node = kwargs["node"] if not self._is_supported_linux_distro(node): raise SkippedException(UnsupportedDistroException(node.os)) + needed_packages = ["python-parted", "python3-parted"] + for package in needed_packages: + if node.os.is_package_in_repo(package): + node.os.install_packages(package) @TestCaseMetadata( description="""