Change:
[X] test pr : kuberenetes/kubernetes 17 June 2021 [x] two weeks soak end date : 1 July 2021 [X] test promotion pr : kubernetes/kubernetes According to this APIsnoop query, there are still some remaining StatafulSet endpoints that are untested. with this query, you can filter untested endpoints by their category and eligibility for conformance. e.g below shows a query to find all conformance eligible untested, stable, core endpoints Create a StatefulSet Patch the StatefulSet List all StatefulSet in the namespace Delete the collection if StatefulSets in the namespace Verify that all StatefulSet was deleted Due to the complexity of setting up the resources for APIService we have used the current e2e test as a template. It has been extended in a for review. example endpoint | useragent ---------------------------------------------|
createAppsV1NamespacedStatefulSet | (linux/amd64) kubernetes/$Format -- [sig-apps] StatefulSet Basic StatefulSet functionality [StatefulSetBasic] should list, patch and delete a collection of StatefulSets deleteAppsV1CollectionNamespacedStatefulSet | (linux/amd64) kubernetes/$Format -- [sig-apps] StatefulSet Basic StatefulSet functionality [StatefulSetBasic] should list, patch and delete a collection of StatefulSets listAppsV1NamespacedStatefulSet | (linux/amd64) kubernetes/$Format -- [sig-apps] StatefulSet Basic StatefulSet functionality [StatefulSetBasic] should list, patch and delete a collection of StatefulSets listAppsV1StatefulSetForAllNamespaces | (linux/amd64) kubernetes/$Format -- [sig-apps] StatefulSet Basic StatefulSet functionality [StatefulSetBasic] should list, patch and delete a collection of StatefulSets patchAppsV1NamespacedStatefulSet | (linux/amd64) kubernetes/$Format -- [sig-apps] StatefulSet Basic StatefulSet functionality [StatefulSetBasic] should list, patch and delete a collection of StatefulSets readAppsV1NamespacedStatefulSet | (linux/amd64) kubernetes/$Format -- [sig-apps] StatefulSet Basic StatefulSet functionality [StatefulSetBasic] should list, patch and delete a collection of StatefulSets replaceAppsV1NamespacedStatefulSetStatus | kube-controller-manager/v1.20.4 (linux/amd64) kubernetes//system:serviceaccount:kube-system:statefulset-controller (7 rows) If a test with these calls gets merged, test coverage will go up by 3 points This test is also created with the goal of conformance promotion. /sig apps /sig testing /sig architecture /area conformance
/triage accepted
/reopen
Reopened this issue. <detailsIn response to : /reopen Instructions for interacting with me using PR comments are available . If you have questions or suggestions related to my behavior, please file an issue against the repository. </details

Discussion:
framework.ExpectEqual(*(ss.Spec.Replicas), int32(4), "statefulset should have 4 replicas") }) <ins> ginkgo.It("should list, patch and delete a collection of StatefulSets", func() { ssPatchReplicas := int32(2) ssPatchImage := imageutils.GetE2EImage(imageutils.Pause) one := int64(1) ssName := "test-ss" // Define StatefulSet Labels ssPodLabels := map[string]string{ "name": "sample-pod", "pod":  WebserverImageName, } ss := e2estatefulset.NewStatefulSet(ssName, ns, headlessSvcName, 1, nil, nil, ssPodLabels) setHTTPProbe(ss) ss, err := c.AppsV1().StatefulSets(ns).Create(context.TODO(), ss, metav1.CreateOptions{}) framework.ExpectNoError(err) e2estatefulset.WaitForRunningAndReady(c, *ss.Spec.Replicas, ss) waitForStatus(c, ss) ginkgo.By("patching the StatefulSet") ssPatch, err := json.Marshal(map[string]interface{}{ "metadata": map[string]interface{}{ "labels": map[string]string{"test-ss": "patched"}, }, "spec": map[string]interface{}{ "replicas": ssPatchReplicas, "template": map[string]interface{}{ "spec": map[string]interface{}{ "TerminationGracePeriodSeconds": &one, "containers": [1]map[string]interface{}{{ "name":  ssName, "image": ssPatchImage, }}, }, }, }, }) framework.ExpectNoError(err, "failed to Marshal StatefulSet JSON patch") _, err = f.ClientSet.AppsV1().StatefulSets(ns).Patch(context.TODO(), ssName, types.StrategicMergePatchType, []byte(ssPatch), metav1.PatchOptions{}) framework.ExpectNoError(err, "failed to patch Set") ss, err = c.AppsV1().StatefulSets(ns).Get(context.TODO(), ssName, metav1.GetOptions{}) framework.ExpectNoError(err, "Failed to get statefulset resource: %v", err) framework.ExpectEqual(*(ss.Spec.Replicas), ssPatchReplicas, "statefulset should have 2 replicas") framework.ExpectEqual(ss.Spec.Template.Spec.Containers[0].Image, ssPatchImage, "statefulset not using ssPatchImage. Is using %v", ss.Spec.Template.Spec.Containers[0].Image) e2estatefulset.WaitForRunningAndReady(c, *ss.Spec.Replicas, ss) waitForStatus(c, ss) ginkgo.By("Listing all StatefulSets") ssList, err := c.AppsV1().StatefulSets("").List(context.TODO(), metav1.ListOptions{LabelSelector: "test-ss=patched"}) framework.ExpectNoError(err, "failed to list StatefulSets") framework.ExpectEqual(len(ssList.Items), 1, "filtered list wasn't found") ginkgo.By("Delete all of the StatefulSets") err = c.AppsV1().StatefulSets(ns).DeleteCollection(context.TODO(), metav1.DeleteOptions{GracePeriodSeconds: &one}, metav1.ListOptions{LabelSelector: "test-ss=patched"}) framework.ExpectNoError(err, "failed to delete StatefulSets") ginkgo.By("Verify that StatefulSets have been deleted") ssList, err = c.AppsV1().StatefulSets("").List(context.TODO(), metav1.ListOptions{LabelSelector: "test-ss=patched"}) framework.ExpectNoError(err, "failed to list StatefulSets") framework.ExpectEqual(len(ssList.Items), 0, "filtered list should have no Statefulsets") }) </ins> ginkgo.It("should validate Statefulset Status endpoints", func() { ssClient := c.AppsV1().StatefulSets(ns) labelSelector := "e2e=testing"