mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-27 13:37:30 +00:00
Remove wildcard matching of no-op test webhooks
This commit is contained in:
parent
e40ffd7197
commit
cd06e4db1f
@ -788,10 +788,11 @@ func testWebhookForWebhookConfigurations(f *framework.Framework) {
|
|||||||
Name: "should-be-removable-validating-webhook.k8s.io",
|
Name: "should-be-removable-validating-webhook.k8s.io",
|
||||||
Rules: []v1beta1.RuleWithOperations{{
|
Rules: []v1beta1.RuleWithOperations{{
|
||||||
Operations: []v1beta1.OperationType{v1beta1.Create},
|
Operations: []v1beta1.OperationType{v1beta1.Create},
|
||||||
|
// This will not match any real resources so this webhook should never be called.
|
||||||
Rule: v1beta1.Rule{
|
Rule: v1beta1.Rule{
|
||||||
APIGroups: []string{"*"},
|
APIGroups: []string{""},
|
||||||
APIVersions: []string{"*"},
|
APIVersions: []string{"v1"},
|
||||||
Resources: []string{"*"},
|
Resources: []string{"invalid"},
|
||||||
},
|
},
|
||||||
}},
|
}},
|
||||||
ClientConfig: v1beta1.WebhookClientConfig{
|
ClientConfig: v1beta1.WebhookClientConfig{
|
||||||
@ -831,10 +832,11 @@ func testWebhookForWebhookConfigurations(f *framework.Framework) {
|
|||||||
Name: "should-be-removable-mutating-webhook.k8s.io",
|
Name: "should-be-removable-mutating-webhook.k8s.io",
|
||||||
Rules: []v1beta1.RuleWithOperations{{
|
Rules: []v1beta1.RuleWithOperations{{
|
||||||
Operations: []v1beta1.OperationType{v1beta1.Create},
|
Operations: []v1beta1.OperationType{v1beta1.Create},
|
||||||
|
// This will not match any real resources so this webhook should never be called.
|
||||||
Rule: v1beta1.Rule{
|
Rule: v1beta1.Rule{
|
||||||
APIGroups: []string{"*"},
|
APIGroups: []string{""},
|
||||||
APIVersions: []string{"*"},
|
APIVersions: []string{"v1"},
|
||||||
Resources: []string{"*"},
|
Resources: []string{"invalid"},
|
||||||
},
|
},
|
||||||
}},
|
}},
|
||||||
ClientConfig: v1beta1.WebhookClientConfig{
|
ClientConfig: v1beta1.WebhookClientConfig{
|
||||||
|
Loading…
Reference in New Issue
Block a user