From d2ae8bd63908ef4de6a0e552f32dc3b0c024fa87 Mon Sep 17 00:00:00 2001 From: Jilju Joy Date: Wed, 16 Oct 2024 14:58:26 +0530 Subject: [PATCH] Remove provider mode skip marker from space reclaim tests (#10571) Signed-off-by: Jilju Joy --- .../space_reclaim/test_rbd_space_reclaim.py | 21 ++++++++++--------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/tests/functional/pv/space_reclaim/test_rbd_space_reclaim.py b/tests/functional/pv/space_reclaim/test_rbd_space_reclaim.py index 4edb3b5da9d..8948b1b618c 100644 --- a/tests/functional/pv/space_reclaim/test_rbd_space_reclaim.py +++ b/tests/functional/pv/space_reclaim/test_rbd_space_reclaim.py @@ -3,6 +3,7 @@ import pytest +from ocs_ci.framework import config from ocs_ci.ocs import constants from ocs_ci.framework.pytest_customization.marks import green_squad from ocs_ci.framework.testlib import ( @@ -12,7 +13,6 @@ tier2, polarion_id, skipif_managed_service, - skipif_hci_provider_and_client, skipif_external_mode, ) from ocs_ci.ocs.exceptions import ( @@ -25,7 +25,7 @@ check_file_existence, delete_pods, ) -from ocs_ci.helpers.helpers import fetch_used_size +from ocs_ci.helpers.helpers import fetch_used_size, default_storage_class from ocs_ci.utility.utils import TimeoutSampler log = logging.getLogger(__name__) @@ -47,11 +47,15 @@ def setup(self, project_factory, storageclass_factory, create_pvcs_and_pods): """ self.pool_replica = 3 pvc_size_gi = 25 - self.sc_obj = storageclass_factory( - interface=constants.CEPHBLOCKPOOL, - replica=self.pool_replica, - new_rbd_pool=True, - ) + if config.ENV_DATA["platform"] in constants.HCI_PROVIDER_CLIENT_PLATFORMS: + self.sc_obj = default_storage_class(interface_type=constants.CEPHBLOCKPOOL) + else: + self.sc_obj = storageclass_factory( + interface=constants.CEPHBLOCKPOOL, + replica=self.pool_replica, + new_rbd_pool=True, + ) + self.pvc, self.pod = create_pvcs_and_pods( pvc_size=pvc_size_gi, access_modes_rbd=[constants.ACCESS_MODE_RWO], @@ -64,7 +68,6 @@ def setup(self, project_factory, storageclass_factory, create_pvcs_and_pods): @tier1 @skipif_external_mode @skipif_managed_service - @skipif_hci_provider_and_client def test_rbd_space_reclaim(self): """ Test to verify RBD space reclamation @@ -148,7 +151,6 @@ def test_rbd_space_reclaim(self): @polarion_id("OCS-2774") @tier1 @skipif_managed_service - @skipif_hci_provider_and_client @skipif_external_mode def test_rbd_space_reclaim_no_space(self): """ @@ -205,7 +207,6 @@ def test_rbd_space_reclaim_no_space(self): @polarion_id("OCS-3733") @tier2 @skipif_external_mode - @skipif_hci_provider_and_client def test_no_volume_mounted(self): """ Test reclaimspace job with no volume mounted