Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions tests/storage/test_data_import_cron.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,7 @@ def second_object_cleanup(
resource_class(namespace=namespace.name, name=second_object_name).clean_up()


@pytest.mark.gating
@pytest.mark.polarion("CNV-7602")
@pytest.mark.s390x
def test_data_import_cron_garbage_collection(
Expand Down
2 changes: 2 additions & 0 deletions utilities/storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -1013,13 +1013,15 @@ def wait_for_volume_snapshot_ready_to_use(namespace, name):
ready_to_use_status = "readyToUse"
LOGGER.info(f"Wait for VolumeSnapshot '{name}' in '{namespace}' to be '{ready_to_use_status}'")
volume_snapshot = VolumeSnapshot(namespace=namespace, name=name)
volume_snapshot.wait()
try:
for sample in TimeoutSampler(
wait_timeout=TIMEOUT_5MIN,
sleep=TIMEOUT_5SEC,
func=lambda: volume_snapshot.instance.get("status", {}).get(ready_to_use_status) is True,
):
if sample:
LOGGER.info(f"VolumeSnapshot '{name}' in namespace '{namespace}' reached '{ready_to_use_status}'")
return volume_snapshot
except TimeoutExpiredError:
fail_msg = f"failed to reach {ready_to_use_status} status" if volume_snapshot.exists else "failed to create"
Expand Down
Loading