ceph-csi icon indicating copy to clipboard operation
ceph-csi copied to clipboard

e2e: validate snapshot count after their creation

Open pkalever opened this issue 3 years ago • 1 comments

Describe the bug

As a good practice, always make sure to validate the snapshot count after we create them in the tests Something like:

err = createSnapshot(&snap, deployTimeout)                            
if err != nil {                                                       
    e2elog.Failf("failed to create snapshot (%s): %v", snap.Name, err)
}                                                                     
snaps, err := listCephFSSnapshots(f, fileSystemName, subvolumes[0].Name, subvolumegroup)    
if err != nil {                                                                             
    e2elog.Failf("failed to list subvolume snapshots: %v", err)                             
}                                                                                           
if len(snaps) == 0 {                                                                        
    e2elog.Failf("cephFS snapshots list is empty %s/%s", fileSystemName, subvolumes[0].Name)
}                                                                                           

Original conversation

pkalever avatar Jun 29 '22 11:06 pkalever

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in a week if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Aug 08 '22 21:08 github-actions[bot]