From 97ef0f515a3e57f1393973d5078bebed2c5568cf Mon Sep 17 00:00:00 2001 From: Madhu Rajanna Date: Tue, 10 Sep 2024 15:02:15 +0200 Subject: [PATCH] ci: test ony commit testing this by pacing the test in the biginning to fail early Signed-off-by: Madhu Rajanna --- e2e/cephfs.go | 33 +++++++++++++++++++-------------- 1 file changed, 19 insertions(+), 14 deletions(-) diff --git a/e2e/cephfs.go b/e2e/cephfs.go index 9c336dd8f1f8..f790c42477b7 100644 --- a/e2e/cephfs.go +++ b/e2e/cephfs.go @@ -331,13 +331,30 @@ var _ = Describe(cephfsType, func() { }) } - By("verify mountOptions support", func() { + By("Create volumeGroupSnapshot", func() { err := createCephfsStorageClass(f.ClientSet, f, true, nil) if err != nil { framework.Failf("failed to create CephFS storageclass: %v", err) } + scName := "csi-cephfs-sc" + base, err := newVolumeGroupSnapshotBase(f, scName, f.UniqueName, false, deployTimeout, 3) + if err != nil { + framework.Failf("failed to create volumeGroupSnapshot Base: %v", err) + } + snapshotter := newCephFSVolumeGroupSnapshot(f) + err = base.testVolumeGroupSnapshot(snapshotter) + if err != nil { + framework.Failf("failed to test volumeGroupSnapshot: %v", err) + } - err = verifySeLinuxMountOption(f, pvcPath, appPath, + err = deleteResource(cephFSExamplePath + "storageclass.yaml") + if err != nil { + framework.Failf("failed to delete CephFS storageclass: %v", err) + } + }) + + By("verify mountOptions support", func() { + err := verifySeLinuxMountOption(f, pvcPath, appPath, cephFSDeamonSetName, cephFSContainerName, cephCSINamespace) if err != nil { framework.Failf("failed to verify mount options: %v", err) @@ -2488,18 +2505,6 @@ var _ = Describe(cephfsType, func() { return } - By("Create volumeGroupSnapshot", func() { - scName := "csi-cephfs-sc" - base, err := newVolumeGroupSnapshotBase(f, scName, f.UniqueName, false, deployTimeout, 3) - if err != nil { - framework.Failf("failed to create volumeGroupSnapshot Base: %v", err) - } - snapshotter := newCephFSVolumeGroupSnapshot(f) - err = base.testVolumeGroupSnapshot(snapshotter) - if err != nil { - framework.Failf("failed to test volumeGroupSnapshot: %v", err) - } - }) // Make sure this should be last testcase in this file, because // it deletes pool By("Create a PVC and delete PVC when backend pool deleted", func() {