From f5b0930665ac36e853f254c3db681b6f4368e691 Mon Sep 17 00:00:00 2001 From: Chad Smith Date: Sat, 12 Nov 2022 11:36:59 -0700 Subject: tests: test_lxd assert features.storage.buckets when present (#1827) LXD v 5.5 introduces a features.storage.buckets default. Assert features.storage.buckets when host provides this key. Cope with versions that do not surface this config. --- tests/integration_tests/modules/test_lxd.py | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/tests/integration_tests/modules/test_lxd.py b/tests/integration_tests/modules/test_lxd.py index 9f0cff10..01d35613 100644 --- a/tests/integration_tests/modules/test_lxd.py +++ b/tests/integration_tests/modules/test_lxd.py @@ -218,14 +218,8 @@ def validate_preseed_projects(client: IntegrationInstance, preseed_cfg): # `features.storage.buckets` was introduced in lxd 5.5 . More info: # https://discuss.linuxcontainers.org/t/lxd-5-5-has-been-released/14899 - if ImageSpecification.from_os_image().release in ( - "bionic", - "focal", - "jammy", - ): - src_project["config"].pop("features.storage.buckets", None) - project["config"].pop("features.storage.buckets", None) - + if "features.storage.buckets" in project["config"]: + assert "true" == project["config"].pop("features.storage.buckets") assert project == src_project -- cgit v1.2.1