Skip to content

Commit

Permalink
Update PVC expansion check on pods in test (#9162)
Browse files Browse the repository at this point in the history
Signed-off-by: Jilju Joy <[email protected]>
  • Loading branch information
jilju authored Jan 23, 2024
1 parent b1370c4 commit 75f5674
Showing 1 changed file with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -165,11 +165,12 @@ def test_resource_deletion_during_pvc_expansion(self, resource_to_delete):
continue
df_out = df_out.split()
new_size_mount = df_out[df_out.index(pod_obj.get_storage_path()) - 4]
if new_size_mount in [
f"{pvc_size_expanded - 0.1}G",
f"{float(pvc_size_expanded)}G",
f"{pvc_size_expanded}G",
]:
if (
pvc_size_expanded - 0.7
<= float(new_size_mount[:-1])
<= pvc_size_expanded
and new_size_mount[-1] == "G"
):
log.info(
f"Verified: Expanded size of PVC {pod_obj.pvc.name} "
f"is reflected on pod {pod_obj.name}"
Expand Down

0 comments on commit 75f5674

Please sign in to comment.