When reading pvc status allow bound to be a valid value

This commit is contained in:
Stephen Heywood 2023-10-16 10:20:26 +13:00
parent 8e8ac86cf1
commit b548bbb8cf

View File

@ -692,7 +692,7 @@ var _ = utils.SIGDescribe("PersistentVolumes", func() {
retrievedPVC := &v1.PersistentVolumeClaim{}
err = runtime.DefaultUnstructuredConverter.FromUnstructured(pvcUnstructured.UnstructuredContent(), &retrievedPVC)
framework.ExpectNoError(err, "Failed to retrieve %q status.", initialPV.Name)
gomega.Expect(string(retrievedPVC.Status.Phase)).To(gomega.Equal("Pending"), "Checking that the PVC status has been read")
gomega.Expect(string(retrievedPVC.Status.Phase)).To(gomega.Or(gomega.Equal("Pending"), gomega.Equal("Bound")), "Checking that the PVC status has been read")
ginkgo.By(fmt.Sprintf("Reading %q Status", initialPV.Name))
pvResource := schema.GroupVersionResource{Group: "", Version: "v1", Resource: "persistentvolumes"}