From 6621db7dd122ccaa78e49d2e23d5dac855e6908e Mon Sep 17 00:00:00 2001 From: Humble Chirammal Date: Tue, 20 Sep 2022 18:34:12 +0530 Subject: [PATCH] fix typos in pkg/validation and test/cmd Signed-off-by: Humble Chirammal --- pkg/apis/core/v1/helper/helpers_test.go | 2 +- pkg/apis/core/validation/validation.go | 2 +- pkg/apis/core/validation/validation_test.go | 6 +++--- test/cmd/apply.sh | 2 +- test/cmd/discovery.sh | 2 +- test/cmd/template-output.sh | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/pkg/apis/core/v1/helper/helpers_test.go b/pkg/apis/core/v1/helper/helpers_test.go index 70eef601810..e691153e4e5 100644 --- a/pkg/apis/core/v1/helper/helpers_test.go +++ b/pkg/apis/core/v1/helper/helpers_test.go @@ -550,7 +550,7 @@ func TestNodeSelectorRequirementKeyExistsInNodeSelectorTerms(t *testing.T) { exists: true, }, { - name: "key existence in terms with one of the keys specfied", + name: "key existence in terms with one of the keys specified", reqs: []v1.NodeSelectorRequirement{ { Key: "key1", diff --git a/pkg/apis/core/validation/validation.go b/pkg/apis/core/validation/validation.go index 25476ce69cb..94dc66d80c9 100644 --- a/pkg/apis/core/validation/validation.go +++ b/pkg/apis/core/validation/validation.go @@ -6417,7 +6417,7 @@ func validateWindowsHostProcessPod(podSpec *core.PodSpec, fieldPath *field.Path, switch { case containerHostProcess != nil && *containerHostProcess: - // Container explitly sets hostProcess=true + // Container explicitly sets hostProcess=true hostProcessContainerCount++ case containerHostProcess == nil && podHostProcess != nil && *podHostProcess: // Container inherits hostProcess=true from pod settings diff --git a/pkg/apis/core/validation/validation_test.go b/pkg/apis/core/validation/validation_test.go index 703748b2ffc..ab166ae8b93 100644 --- a/pkg/apis/core/validation/validation_test.go +++ b/pkg/apis/core/validation/validation_test.go @@ -13384,7 +13384,7 @@ func TestValidateServiceCreate(t *testing.T) { numErrs: 0, }, { - name: "nagative healthCheckNodePort field", + name: "negative healthCheckNodePort field", tweakSvc: func(s *core.Service) { s.Spec.Type = core.ServiceTypeLoadBalancer s.Spec.AllocateLoadBalancerNodePorts = utilpointer.BoolPtr(true) @@ -13394,7 +13394,7 @@ func TestValidateServiceCreate(t *testing.T) { numErrs: 1, }, { - name: "nagative healthCheckNodePort field", + name: "negative healthCheckNodePort field", tweakSvc: func(s *core.Service) { s.Spec.Type = core.ServiceTypeLoadBalancer s.Spec.AllocateLoadBalancerNodePorts = utilpointer.BoolPtr(true) @@ -13528,7 +13528,7 @@ func TestValidateServiceCreate(t *testing.T) { }, numErrs: 0, }, - /* cluster IPs. some tests are reduntant */ + /* cluster IPs. some tests are redundant */ { name: "invalid, garbage single ip", tweakSvc: func(s *core.Service) { diff --git a/test/cmd/apply.sh b/test/cmd/apply.sh index 86636197911..b913389decc 100755 --- a/test/cmd/apply.sh +++ b/test/cmd/apply.sh @@ -306,7 +306,7 @@ __EOF__ kubectl delete --kustomize hack/testdata/kustomize ## kubectl apply multiple resources with one failure during apply phase. - # Pre-Condition: namepace does not exist and no POD exists + # Pre-Condition: namespace does not exist and no POD exists output_message=$(! kubectl get namespace multi-resource-ns 2>&1 "${kube_flags[@]:?}") kube::test::if_has_string "${output_message}" 'namespaces "multi-resource-ns" not found' kube::test::wait_object_assert pods "{{range.items}}{{${id_field:?}}}:{{end}}" '' diff --git a/test/cmd/discovery.sh b/test/cmd/discovery.sh index 0db5587e4e5..6355af98d13 100755 --- a/test/cmd/discovery.sh +++ b/test/cmd/discovery.sh @@ -27,7 +27,7 @@ run_RESTMapper_evaluation_tests() { RESTMAPPER_ERROR_FILE="${KUBE_TEMP}/restmapper-error" - ### Non-existent resource type should give a recognizeable error + ### Non-existent resource type should give a recognizable error # Pre-condition: None # Command kubectl get "${kube_flags[@]:?}" unknownresourcetype 2>"${RESTMAPPER_ERROR_FILE}" || true diff --git a/test/cmd/template-output.sh b/test/cmd/template-output.sh index c236530980e..ed1a5c8787c 100755 --- a/test/cmd/template-output.sh +++ b/test/cmd/template-output.sh @@ -201,7 +201,7 @@ EOF output_message=$(kubectl "${kube_flags[@]:?}" create service nodeport foo --dry-run=client --tcp=8080 --template="{{ .metadata.name }}:") kube::test::if_has_string "${output_message}" 'foo:' - # check that "config view" ouputs "yaml" as its default output format + # check that "config view" outputs "yaml" as its default output format output_message=$(kubectl "${kube_flags[@]:?}" config view) kube::test::if_has_string "${output_message}" 'kind: Config'