Merge pull request #97656 from ialidzhikov/staticchec/initializers

Fix staticcheck in staging/src/k8s.io/apiserver/pkg/admission/initializer
This commit is contained in:
Kubernetes Prow Robot 2021-01-05 03:11:58 -08:00 committed by GitHub
commit 7e677be77a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 0 additions and 13 deletions

View File

@ -16,7 +16,6 @@ vendor/k8s.io/apimachinery/pkg/util/net
vendor/k8s.io/apimachinery/pkg/util/sets/types
vendor/k8s.io/apimachinery/pkg/util/strategicpatch
vendor/k8s.io/apimachinery/pkg/util/wait
vendor/k8s.io/apiserver/pkg/admission/initializer
vendor/k8s.io/apiserver/pkg/authentication/request/x509
vendor/k8s.io/apiserver/pkg/endpoints
vendor/k8s.io/apiserver/pkg/endpoints/filters

View File

@ -120,15 +120,3 @@ type TestAuthorizer struct{}
func (t *TestAuthorizer) Authorize(ctx context.Context, a authorizer.Attributes) (authorized authorizer.Decision, reason string, err error) {
return authorizer.DecisionNoOpinion, "", nil
}
// wantClientCert is a test stub for testing that fulfulls the WantsClientCert interface.
type clientCertWanter struct {
gotCert, gotKey []byte
}
func (s *clientCertWanter) SetClientCert(cert, key []byte) { s.gotCert, s.gotKey = cert, key }
func (s *clientCertWanter) Admit(ctx context.Context, a admission.Attributes, o admission.ObjectInterfaces) error {
return nil
}
func (s *clientCertWanter) Handles(o admission.Operation) bool { return false }
func (s *clientCertWanter) ValidateInitialization() error { return nil }