@@ -11,7 +11,7 @@ See the License for the specific language governing permissions and
11
11
limitations under the License.
12
12
*/
13
13
14
- package helpers
14
+ package linked_clone
15
15
16
16
import (
17
17
"context"
@@ -56,6 +56,7 @@ var lcToDelete []*corev1.PersistentVolumeClaim
56
56
/*
57
57
This method will create PVC, attach pod to it and creates snapshot
58
58
*/
59
+ // Keeping this method here as it populates the array used for cleanup
59
60
func CreatePvcPodAndSnapshot (ctx context.Context , e2eTestConfig * config.E2eTestConfig , client clientset.Interface , namespace string , storageclass * v1.StorageClass , doCreatePod bool , doCreateDep bool ) (* corev1.PersistentVolumeClaim , []* corev1.PersistentVolume , * snapV1.VolumeSnapshot ) {
60
61
61
62
fmt .Println ("Create PVC and verify PVC is bound" )
@@ -75,6 +76,7 @@ func CreatePvcPodAndSnapshot(ctx context.Context, e2eTestConfig *config.E2eTestC
75
76
}
76
77
77
78
// Create stand alone or deployment pod as per given arg
79
+ // Keeping this method here as it populates the array used for cleanup
78
80
func CreatePodForPvc (ctx context.Context , e2eTestConfig * config.E2eTestConfig , client clientset.Interface , namespace string , pvclaim []* corev1.PersistentVolumeClaim , deCreatePod bool , doCreateDep bool ) (* corev1.Pod , * appsv1.Deployment ) {
79
81
ginkgo .By ("Create Pod to attach to Pvc" )
80
82
var pod * corev1.Pod
@@ -98,6 +100,7 @@ func CreatePodForPvc(ctx context.Context, e2eTestConfig *config.E2eTestConfig, c
98
100
/*
99
101
Create volume snapshot
100
102
*/
103
+ // Keeping this method here as it populates the array used for cleanup
101
104
func CreateVolumeSnapshot (ctx context.Context , e2eTestConfig * config.E2eTestConfig , namespace string , pvclaim * corev1.PersistentVolumeClaim , pv []* corev1.PersistentVolume , diskSize string ) (* snapV1.VolumeSnapshot , * snapV1.VolumeSnapshotContent ) {
102
105
// Create or get volume snapshot class
103
106
ginkgo .By ("Get or create volume snapshot class" )
@@ -238,7 +241,7 @@ func PvcSpecWithLinkedCloneAnnotation(namespace string, storageclass *storagev1.
238
241
/*
239
242
Verify linked volume lists in list volume
240
243
*/
241
- func ValidateLcInListVolume (ctx context.Context , e2eTestConfig * config.E2eTestConfig , client clientset.Interface , pvc * corev1.PersistentVolumeClaim , namespace string ) {
244
+ func ValidateLinkedCloneInListVolume (ctx context.Context , e2eTestConfig * config.E2eTestConfig , client clientset.Interface , pvc * corev1.PersistentVolumeClaim , namespace string ) {
242
245
ginkgo .By ("Validate ListVolume Response for all the volumes" )
243
246
var logMessage string
244
247
var sshClientConfig * ssh.ClientConfig
@@ -346,7 +349,7 @@ func ParseMi(value string) (int, error) {
346
349
}
347
350
348
351
// This method can be used to create statefulset with linked clone annotation
349
- func CreateAndValidateLcWithSts (ctx context.Context , e2eTestConfig * config.E2eTestConfig , client clientset.Interface , namespace string , sc * v1.StorageClass , snapName string , snapshotapigroup string ) {
352
+ func CreateAndValidateLinkedCloneWithSts (ctx context.Context , e2eTestConfig * config.E2eTestConfig , client clientset.Interface , namespace string , sc * v1.StorageClass , snapName string , snapshotapigroup string ) {
350
353
statefulset := k8testutil .GetStatefulSetFromManifest (e2eTestConfig .TestInput , namespace )
351
354
ginkgo .By ("Creating statefulset" )
352
355
annotations := map [string ]string {
0 commit comments