Skip to content

Commit

Permalink
skip tests that uses default storage class when there is no default s…
Browse files Browse the repository at this point in the history
…torage class installed
  • Loading branch information
leiyiz committed Nov 17, 2021
1 parent 1367cca commit 496ccc0
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions test/e2e/storage/generic_persistent_volume-disruptive.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ var _ = utils.SIGDescribe("GenericPersistentVolume[Disruptive]", func() {
pv *v1.PersistentVolume
)
ginkgo.BeforeEach(func() {
e2epv.SkipIfNoDefaultStorageClass(c)
framework.Logf("Initializing pod and pvcs for test")
clientPod, pvc, pv = createPodPVCFromSC(f, c, ns)
})
Expand Down
1 change: 1 addition & 0 deletions test/e2e/storage/volume_metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ var _ = utils.SIGDescribe("[Serial] Volume metrics", func() {
// and the underlying storage driver and therefore don't pass
// with other kinds of clusters and drivers.
e2eskipper.SkipUnlessProviderIs("gce", "gke", "aws")
e2epv.SkipIfNoDefaultStorageClass(c)
defaultScName, err = e2epv.GetDefaultStorageClassName(c)
framework.ExpectNoError(err)

Expand Down
1 change: 1 addition & 0 deletions test/e2e/storage/volume_provisioning.go
Original file line number Diff line number Diff line change
Expand Up @@ -669,6 +669,7 @@ var _ = utils.SIGDescribe("Dynamic Provisioning", func() {
// Modifying the default storage class can be disruptive to other tests that depend on it
ginkgo.It("should be disabled by removing the default annotation [Serial] [Disruptive]", func() {
e2eskipper.SkipUnlessProviderIs("openstack", "gce", "aws", "gke", "vsphere", "azure")
e2epv.SkipIfNoDefaultStorageClass(c)

scName, scErr := e2epv.GetDefaultStorageClassName(c)
framework.ExpectNoError(scErr)
Expand Down

0 comments on commit 496ccc0

Please sign in to comment.