mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-26 21:17:23 +00:00
Remove all skips from admission and CRD e2e tests that will be promoted to conformance
This commit is contained in:
parent
c008cf95a9
commit
d4958c0bee
@ -30,7 +30,6 @@ import (
|
|||||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
|
"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
|
||||||
"k8s.io/apimachinery/pkg/util/intstr"
|
"k8s.io/apimachinery/pkg/util/intstr"
|
||||||
utilversion "k8s.io/apimachinery/pkg/util/version"
|
|
||||||
"k8s.io/client-go/dynamic"
|
"k8s.io/client-go/dynamic"
|
||||||
clientset "k8s.io/client-go/kubernetes"
|
clientset "k8s.io/client-go/kubernetes"
|
||||||
"k8s.io/kubernetes/test/e2e/framework"
|
"k8s.io/kubernetes/test/e2e/framework"
|
||||||
@ -54,8 +53,6 @@ const (
|
|||||||
roleBindingCRDName = "crd-conversion-webhook-auth-reader"
|
roleBindingCRDName = "crd-conversion-webhook-auth-reader"
|
||||||
)
|
)
|
||||||
|
|
||||||
var serverCRDConversionWebhookVersion = utilversion.MustParseSemantic("v1.13.0-alpha")
|
|
||||||
|
|
||||||
var apiVersions = []apiextensionsv1.CustomResourceDefinitionVersion{
|
var apiVersions = []apiextensionsv1.CustomResourceDefinitionVersion{
|
||||||
{
|
{
|
||||||
Name: "v1",
|
Name: "v1",
|
||||||
@ -129,9 +126,6 @@ var _ = SIGDescribe("CustomResourceConversionWebhook", func() {
|
|||||||
client = f.ClientSet
|
client = f.ClientSet
|
||||||
namespaceName = f.Namespace.Name
|
namespaceName = f.Namespace.Name
|
||||||
|
|
||||||
// Make sure the relevant provider supports conversion webhook
|
|
||||||
framework.SkipUnlessServerVersionGTE(serverCRDConversionWebhookVersion, f.ClientSet.Discovery())
|
|
||||||
|
|
||||||
ginkgo.By("Setting up server cert")
|
ginkgo.By("Setting up server cert")
|
||||||
context = setupServerCert(f.Namespace.Name, serviceCRDName)
|
context = setupServerCert(f.Namespace.Name, serviceCRDName)
|
||||||
createAuthReaderRoleBindingForCRDConversion(f, f.Namespace.Name)
|
createAuthReaderRoleBindingForCRDConversion(f, f.Namespace.Name)
|
||||||
|
@ -35,7 +35,6 @@ import (
|
|||||||
apiequality "k8s.io/apimachinery/pkg/api/equality"
|
apiequality "k8s.io/apimachinery/pkg/api/equality"
|
||||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
"k8s.io/apimachinery/pkg/types"
|
"k8s.io/apimachinery/pkg/types"
|
||||||
utilversion "k8s.io/apimachinery/pkg/util/version"
|
|
||||||
"k8s.io/apimachinery/pkg/util/wait"
|
"k8s.io/apimachinery/pkg/util/wait"
|
||||||
k8sclientset "k8s.io/client-go/kubernetes"
|
k8sclientset "k8s.io/client-go/kubernetes"
|
||||||
"k8s.io/client-go/rest"
|
"k8s.io/client-go/rest"
|
||||||
@ -47,17 +46,12 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
crdPublishOpenAPIVersion = utilversion.MustParseSemantic("v1.14.0")
|
metaPattern = `"kind":"%s","apiVersion":"%s/%s","metadata":{"name":"%s"}`
|
||||||
metaPattern = `"kind":"%s","apiVersion":"%s/%s","metadata":{"name":"%s"}`
|
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ = SIGDescribe("CustomResourcePublishOpenAPI", func() {
|
var _ = SIGDescribe("CustomResourcePublishOpenAPI", func() {
|
||||||
f := framework.NewDefaultFramework("crd-publish-openapi")
|
f := framework.NewDefaultFramework("crd-publish-openapi")
|
||||||
|
|
||||||
ginkgo.BeforeEach(func() {
|
|
||||||
framework.SkipUnlessServerVersionGTE(crdPublishOpenAPIVersion, f.ClientSet.Discovery())
|
|
||||||
})
|
|
||||||
|
|
||||||
ginkgo.It("works for CRD with validation schema", func() {
|
ginkgo.It("works for CRD with validation schema", func() {
|
||||||
crd, err := setupCRD(f, schemaFoo, "foo", "v1")
|
crd, err := setupCRD(f, schemaFoo, "foo", "v1")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
@ -46,8 +46,6 @@ var _ = SIGDescribe("CustomResourceDefinition Watch", func() {
|
|||||||
*/
|
*/
|
||||||
ginkgo.It("watch on custom resource definition objects", func() {
|
ginkgo.It("watch on custom resource definition objects", func() {
|
||||||
|
|
||||||
framework.SkipUnlessServerVersionGTE(crdVersion, f.ClientSet.Discovery())
|
|
||||||
|
|
||||||
const (
|
const (
|
||||||
watchCRNameA = "name1"
|
watchCRNameA = "name1"
|
||||||
watchCRNameB = "name2"
|
watchCRNameB = "name2"
|
||||||
|
@ -29,15 +29,12 @@ import (
|
|||||||
"k8s.io/apimachinery/pkg/types"
|
"k8s.io/apimachinery/pkg/types"
|
||||||
"k8s.io/apimachinery/pkg/util/diff"
|
"k8s.io/apimachinery/pkg/util/diff"
|
||||||
"k8s.io/apimachinery/pkg/util/uuid"
|
"k8s.io/apimachinery/pkg/util/uuid"
|
||||||
utilversion "k8s.io/apimachinery/pkg/util/version"
|
|
||||||
"k8s.io/client-go/dynamic"
|
"k8s.io/client-go/dynamic"
|
||||||
"k8s.io/client-go/util/retry"
|
"k8s.io/client-go/util/retry"
|
||||||
"k8s.io/kubernetes/test/e2e/framework"
|
"k8s.io/kubernetes/test/e2e/framework"
|
||||||
e2elog "k8s.io/kubernetes/test/e2e/framework/log"
|
e2elog "k8s.io/kubernetes/test/e2e/framework/log"
|
||||||
)
|
)
|
||||||
|
|
||||||
var crdVersion = utilversion.MustParseSemantic("v1.7.0")
|
|
||||||
|
|
||||||
var _ = SIGDescribe("CustomResourceDefinition resources", func() {
|
var _ = SIGDescribe("CustomResourceDefinition resources", func() {
|
||||||
|
|
||||||
f := framework.NewDefaultFramework("custom-resource-definition")
|
f := framework.NewDefaultFramework("custom-resource-definition")
|
||||||
|
@ -36,7 +36,6 @@ import (
|
|||||||
"k8s.io/apimachinery/pkg/types"
|
"k8s.io/apimachinery/pkg/types"
|
||||||
"k8s.io/apimachinery/pkg/util/intstr"
|
"k8s.io/apimachinery/pkg/util/intstr"
|
||||||
"k8s.io/apimachinery/pkg/util/uuid"
|
"k8s.io/apimachinery/pkg/util/uuid"
|
||||||
utilversion "k8s.io/apimachinery/pkg/util/version"
|
|
||||||
"k8s.io/apimachinery/pkg/util/wait"
|
"k8s.io/apimachinery/pkg/util/wait"
|
||||||
"k8s.io/client-go/dynamic"
|
"k8s.io/client-go/dynamic"
|
||||||
clientset "k8s.io/client-go/kubernetes"
|
clientset "k8s.io/client-go/kubernetes"
|
||||||
@ -77,8 +76,6 @@ const (
|
|||||||
addedLabelValue = "yes"
|
addedLabelValue = "yes"
|
||||||
)
|
)
|
||||||
|
|
||||||
var serverWebhookVersion = utilversion.MustParseSemantic("v1.8.0")
|
|
||||||
|
|
||||||
var _ = SIGDescribe("AdmissionWebhook", func() {
|
var _ = SIGDescribe("AdmissionWebhook", func() {
|
||||||
var context *certContext
|
var context *certContext
|
||||||
f := framework.NewDefaultFramework("webhook")
|
f := framework.NewDefaultFramework("webhook")
|
||||||
@ -92,15 +89,6 @@ var _ = SIGDescribe("AdmissionWebhook", func() {
|
|||||||
client = f.ClientSet
|
client = f.ClientSet
|
||||||
namespaceName = f.Namespace.Name
|
namespaceName = f.Namespace.Name
|
||||||
|
|
||||||
// Make sure the relevant provider supports admission webhook
|
|
||||||
framework.SkipUnlessServerVersionGTE(serverWebhookVersion, f.ClientSet.Discovery())
|
|
||||||
framework.SkipUnlessProviderIs("gce", "gke", "local")
|
|
||||||
|
|
||||||
_, err := f.ClientSet.AdmissionregistrationV1().ValidatingWebhookConfigurations().List(metav1.ListOptions{})
|
|
||||||
if errors.IsNotFound(err) {
|
|
||||||
framework.Skipf("dynamic configuration of webhooks requires the admissionregistration.k8s.io group to be enabled")
|
|
||||||
}
|
|
||||||
|
|
||||||
// Make sure the namespace created for the test is labeled to be selected by the webhooks
|
// Make sure the namespace created for the test is labeled to be selected by the webhooks
|
||||||
labelNamespace(f, f.Namespace.Name)
|
labelNamespace(f, f.Namespace.Name)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user