Repository: kubernetes-sigs/cluster-api-provider-aws
Pull request #3189 (2022-02-10 18:20:38)

Test cases added for secondary cidr file
<!-- Thanks for this PR! If this is your first PR please read the [contributing guide](../CONTRIBUTING.md) -->
<!-- If this PR is still work-in-progress and is being open for visibility please prefix the title with `WIP:` -->

**What type of PR is this?**
/area testing
<!--
Add one of the following kinds:
/kind feature
/kind bug
/kind api-change
/kind cleanup
/kind deprecation
/kind design
/kind documentation
/kind failing-test
/kind flake
/kind regression
/kind support
-->

**What this PR does / why we need it**:
Added test case for secondarycidr.go file
<!-- Enter a description of the change and why this change is needed -->

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Part of #2910 

**Special notes for your reviewer**:

**Checklist**:
<!-- Put an "X" character inside the brackets of each completed task. Some may be optional depending on the PR in which case these can be deleted -->

- [x] squashed commits
- [ ] includes documentation
- [x] adds unit tests
- [ ] adds or updates e2e tests

**Release note**:
<!--  Write your release note:
1. Enter your extended release note in the below block. 
2. If the PR requires additional action from users switching to the new release, include the string "action required".
2. If no release note is required, just write "NONE"....however we encourage contributors to never use this as release notes are incredible useful.
-->
```release-note
Test coverage for secondarycidr.go updated to 96%
```


Ankitasw: /lgtm
k8s-ci-robot: New changes are detected. LGTM label has been removed.

Patch:
diff --git a/.golangci.yml b/.golangci.yml
index 3fee12e4e..94978e365 100644
--- a/.golangci.yml
+++ b/.golangci.yml
@@ -57,10 +57,7 @@ linters-settings:
     # Maximum length of variable declaration measured in number of characters, after which linter won't suggest using short syntax.
     max-decl-chars: 50
   gci:
-    sections:
-      - standard
-      - default
-      - prefix(sigs.k8s.io/cluster-api)
+    local-prefixes: "sigs.k8s.io/cluster-api"
   importas:
     no-unaliased: false
     alias:
diff --git a/Makefile b/Makefile
index 7ce7ea196..eca6e4cd1 100644
--- a/Makefile
+++ b/Makefile
@@ -43,8 +43,7 @@ KUBETEST_CONF_PATH ?= $(abspath $(E2E_DATA_DIR)/kubetest/conformance.yaml)
 EXP_DIR := exp
 
 # Binaries.
-GO_APIDIFF_BIN := $(BIN_DIR)/go-apidiff
-GO_APIDIFF := $(TOOLS_DIR)/$(GO_APIDIFF_BIN)
+GO_APIDIFF := $(TOOLS_BIN_DIR)/go-apidiff
 CLUSTERCTL := $(BIN_DIR)/clusterctl
 CONTROLLER_GEN := $(TOOLS_BIN_DIR)/controller-gen
 CONVERSION_GEN := $(TOOLS_BIN_DIR)/conversion-gen
@@ -124,7 +123,7 @@ USE_EXISTING_CLUSTER ?= "false"
 
 # Set E2E_SKIP_EKS_UPGRADE to false to test EKS upgrades.
 # Warning, this takes a long time
-E2E_SKIP_EKS_UPGRADE ?= "false"
+E2E_SKIP_EKS_UPGRADE ?= "true"
 
 # Set EKS_SOURCE_TEMPLATE to override the source template
 EKS_SOURCE_TEMPLATE ?= eks/cluster-template-eks-control-plane-only.yaml
@@ -314,10 +313,6 @@ verify-gen: generate ## Verify generated files
 		echo "generated files are out of date, run make generate"; exit 1; \
 	fi
 
-.PHONY: apidiff
-apidiff: $(GO_APIDIFF) ## Check for API differences
-	$(GO_APIDIFF) $(shell git rev-parse origin/main) --print-compatible
-
 ##@ build:
 
 .PHONY: binaries
@@ -634,4 +629,3 @@ clean-temporary: ## Remove all temporary files and folders
 	rm -rf test/e2e/capi-kubeadm-control-plane-controller-manager
 	rm -rf test/e2e/logs
 	rm -rf test/e2e/resources
-
diff --git a/README.md b/README.md
index 6d4e3a211..d005f3b60 100644
--- a/README.md
+++ b/README.md
@@ -10,12 +10,6 @@
 <!-- goreportcard badge -->
 <a href="https://goreportcard.com/report/sigs.k8s.io/cluster-api-provider-aws">
 <img src="https://goreportcard.com/badge/sigs.k8s.io/cluster-api-provider-aws"></a>
-<!-- join kubernetes slack channel for cluster-api-aws-provider -->
-<a href="http://slack.k8s.io/">
-<img src="https://img.shields.io/badge/join%20slack-%23cluster--api--aws-brightgreen"></a>
-<!-- openssf badge -->
-<a href="https://bestpractices.coreinfrastructure.org/projects/5688">
-<img src="https://bestpractices.coreinfrastructure.org/projects/5688/badge"></a>
 </p>
 
 ------
diff --git a/api/v1alpha3/awscluster_conversion.go b/api/v1alpha3/awscluster_conversion.go
index abd18f90b..96694aa3b 100644
--- a/api/v1alpha3/awscluster_conversion.go
+++ b/api/v1alpha3/awscluster_conversion.go
@@ -61,7 +61,6 @@ func (r *AWSCluster) ConvertTo(dstRaw conversion.Hub) error {
 // Assumes restored and dst are non-nil.
 func restoreControlPlaneLoadBalancer(restored, dst *infrav1.AWSLoadBalancerSpec) {
 	dst.Name = restored.Name
-	dst.HealthCheckProtocol = restored.HealthCheckProtocol
 }
 
 // ConvertFrom converts the v1beta1 AWSCluster receiver to a v1alpha3 AWSCluster.
diff --git a/api/v1alpha3/zz_generated.conversion.go b/api/v1alpha3/zz_generated.conversion.go
index edff3fd47..753b6074b 100644
--- a/api/v1alpha3/zz_generated.conversion.go
+++ b/api/v1alpha3/zz_generated.conversion.go
@@ -1056,7 +1056,6 @@ func autoConvert_v1beta1_AWSLoadBalancerSpec_To_v1alpha3_AWSLoadBalancerSpec(in
 	out.Scheme = (*ClassicELBScheme)(unsafe.Pointer(in.Scheme))
 	out.CrossZoneLoadBalancing = in.CrossZoneLoadBalancing
 	out.Subnets = *(*[]string)(unsafe.Pointer(&in.Subnets))
-	// WARNING: in.HealthCheckProtocol requires manual conversion: does not exist in peer-type
 	out.AdditionalSecurityGroups = *(*[]string)(unsafe.Pointer(&in.AdditionalSecurityGroups))
 	return nil
 }
diff --git a/api/v1alpha4/awscluster_conversion.go b/api/v1alpha4/awscluster_conversion.go
index 983f9285c..82345a690 100644
--- a/api/v1alpha4/awscluster_conversion.go
+++ b/api/v1alpha4/awscluster_conversion.go
@@ -52,7 +52,6 @@ func (src *AWSCluster) ConvertTo(dstRaw conversion.Hub) error {
 // Assumes restored and dst are non-nil.
 func restoreControlPlaneLoadBalancer(restored, dst *infrav1.AWSLoadBalancerSpec) {
 	dst.Name = restored.Name
-	dst.HealthCheckProtocol = restored.HealthCheckProtocol
 }
 
 // ConvertFrom converts the v1beta1 AWSCluster receiver to a v1alpha4 AWSCluster.
diff --git a/api/v1alpha4/zz_generated.conversion.go b/api/v1alpha4/zz_generated.conversion.go
index 2d398170b..5f475d0d9 100644
--- a/api/v1alpha4/zz_generated.conversion.go
+++ b/api/v1alpha4/zz_generated.conversion.go
@@ -1219,7 +1219,6 @@ func autoConvert_v1beta1_AWSLoadBalancerSpec_To_v1alpha4_AWSLoadBalancerSpec(in
 	out.Scheme = (*ClassicELBScheme)(unsafe.Pointer(in.Scheme))
 	out.CrossZoneLoadBalancing = in.CrossZoneLoadBalancing
 	out.Subnets = *(*[]string)(unsafe.Pointer(&in.Subnets))
-	// WARNING: in.HealthCheckProtocol requires manual conversion: does not exist in peer-type
 	out.AdditionalSecurityGroups = *(*[]string)(unsafe.Pointer(&in.AdditionalSecurityGroups))
 	return nil
 }
diff --git a/api/v1beta1/awscluster_types.go b/api/v1beta1/awscluster_types.go
index 984d36625..70c3a030f 100644
--- a/api/v1beta1/awscluster_types.go
+++ b/api/v1beta1/awscluster_types.go
@@ -177,11 +177,6 @@ type AWSLoadBalancerSpec struct {
 	// +optional
 	Subnets []string `json:"subnets,omitempty"`
 
-	// HealthCheckProtocol sets the protocol type for classic ELB health check target
-	// default value is ClassicELBProtocolSSL
-	// +optional
-	HealthCheckProtocol *ClassicELBProtocol `json:"healthCheckProtocol,omitempty"`
-
 	// AdditionalSecurityGroups sets the security groups used by the load balancer. Expected to be security group IDs
 	// This is optional - if not provided new security groups will be created for the load balancer
 	// +optional
diff --git a/api/v1beta1/awscluster_webhook.go b/api/v1beta1/awscluster_webhook.go
index d827a2fe3..31d930100 100644
--- a/api/v1beta1/awscluster_webhook.go
+++ b/api/v1beta1/awscluster_webhook.go
@@ -115,16 +115,6 @@ func (r *AWSCluster) ValidateUpdate(old runtime.Object) error {
 					r.Spec.ControlPlaneLoadBalancer.Name, "field is immutable"),
 			)
 		}
-
-		// Block the update for HealthCheckProtocol :
-		// - if it was not set in old spec but added in new spec
-		// - if it was set in old spec but changed in new spec
-		if !reflect.DeepEqual(newLoadBalancer.HealthCheckProtocol, existingLoadBalancer.HealthCheckProtocol) {
-			allErrs = append(allErrs,
-				field.Invalid(field.NewPath("spec", "controlPlaneLoadBalancer", "healthCheckProtocol"),
-					newLoadBalancer.HealthCheckProtocol, "field is immutable once set"),
-			)
-		}
 	}
 
 	if !reflect.DeepEqual(oldC.Spec.ControlPlaneEndpoint, clusterv1.APIEndpoint{}) &&
diff --git a/api/v1beta1/network_types.go b/api/v1beta1/network_types.go
index 65c0fbfa5..46224ff8b 100644
--- a/api/v1beta1/network_types.go
+++ b/api/v1beta1/network_types.go
@@ -54,10 +54,6 @@ func (e ClassicELBScheme) String() string {
 // ClassicELBProtocol defines listener protocols for a classic load balancer.
 type ClassicELBProtocol string
 
-func (e ClassicELBProtocol) String() string {
-	return string(e)
-}
-
 var (
 	// ClassicELBProtocolTCP defines the ELB API string representing the TCP protocol.
 	ClassicELBProtocolTCP = ClassicELBProtocol("TCP")
diff --git a/api/v1beta1/zz_generated.deepcopy.go b/api/v1beta1/zz_generated.deepcopy.go
index 839659a1b..4bc96f4d8 100644
--- a/api/v1beta1/zz_generated.deepcopy.go
+++ b/api/v1beta1/zz_generated.deepcopy.go
@@ -558,11 +558,6 @@ func (in *AWSLoadBalancerSpec) DeepCopyInto(out *AWSLoadBalancerSpec) {
 		*out = make([]string, len(*in))
 		copy(*out, *in)
 	}
-	if in.HealthCheckProtocol != nil {
-		in, out := &in.HealthCheckProtocol, &out.HealthCheckProtocol
-		*out = new(ClassicELBProtocol)
-		**out = **in
-	}
 	if in.AdditionalSecurityGroups != nil {
 		in, out := &in.AdditionalSecurityGroups, &out.AdditionalSecurityGroups
 		*out = make([]string, len(*in))
diff --git a/config/crd/bases/infrastructure.cluster.x-k8s.io_awsclusters.yaml b/config/crd/bases/infrastructure.cluster.x-k8s.io_awsclusters.yaml
index 248d52b68..5698d7af6 100644
--- a/config/crd/bases/infrastructure.cluster.x-k8s.io_awsclusters.yaml
+++ b/config/crd/bases/infrastructure.cluster.x-k8s.io_awsclusters.yaml
@@ -1651,10 +1651,6 @@ spec:
                       registered instances in its Availability Zone only. \n Defaults
                       to false."
                     type: boolean
-                  healthCheckProtocol:
-                    description: HealthCheckProtocol sets the protocol type for classic
-                      ELB health check target default value is ClassicELBProtocolSSL
-                    type: string
                   name:
                     description: Name sets the name of the classic ELB load balancer.
                       As per AWS, the name must be unique within your set of load
diff --git a/config/crd/bases/infrastructure.cluster.x-k8s.io_awsclustertemplates.yaml b/config/crd/bases/infrastructure.cluster.x-k8s.io_awsclustertemplates.yaml
index 7d4620943..9af2c5b64 100644
--- a/config/crd/bases/infrastructure.cluster.x-k8s.io_awsclustertemplates.yaml
+++ b/config/crd/bases/infrastructure.cluster.x-k8s.io_awsclustertemplates.yaml
@@ -474,11 +474,6 @@ spec:
                               registered instances in its Availability Zone only.
                               \n Defaults to false."
                             type: boolean
-                          healthCheckProtocol:
-                            description: HealthCheckProtocol sets the protocol type
-                              for classic ELB health check target default value is
-                              ClassicELBProtocolSSL
-                            type: string
                           name:
                             description: Name sets the name of the classic ELB load
                               balancer. As per AWS, the name must be unique within
diff --git a/docs/book/src/topics/multitenancy.md b/docs/book/src/topics/multitenancy.md
index b76369d63..8c293266b 100644
--- a/docs/book/src/topics/multitenancy.md
+++ b/docs/book/src/topics/multitenancy.md
@@ -158,6 +158,7 @@ spec:
   roleARN: arn:aws:iam::11122233344:role/multi-tenancy-role
   sessionName: multi-tenancy-role-session
   sourceidentityRef:
+    apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
     kind: AWSClusterControllerIdentity
     name: default
 ---
@@ -171,15 +172,18 @@ spec:
   roleARN: arn:aws:iam::11122233355:role/multi-tenancy-nested-role
   sessionName: multi-tenancy-nested-role-session
   sourceidentityRef:
+    apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
     kind: AWSClusterRoleIdentity
     name: multi-tenancy-role
 ```
 
-## Secure Access to Identities
-`allowedNamespaces` field is used to grant access to the namespaces to use Identities.
+## Secure Access to Identitys
+`allowedNamespaces` field is used to grant access to the namespaces to use Identitys.
 Only AWSClusters that are created in one of the Identity's allowed namespaces can use that Identity.
 `allowedNamespaces` are defined by providing either a list of namespaces or label selector to select namespaces.
 
+Note that the `capa-eks-control-plane-system` namespace will need to be included in the allow namespace list and/or have labels added to allow access to identities used by AWSClusters.
+
 ### Examples
 
 An empty `allowedNamespaces` indicates that the Identity can be used by all namespaces.
@@ -241,7 +245,7 @@ allowedNamespaces:
   selector: {}
 ```
 
-**Important** The default behaviour of an empty label selector is to match all objects, however here we do not follow that behavior to avoid unintended access to the identities.
+**Important** The default behaviour of an empty label selector is to match all objects, however here we do not follow that behavior to avoid unintended access to the identitys.
 This is consistent with core cluster API selectors, e.g., Machine and ClusterResourceSet selectors. The result of matchLabels and matchExpressions are ANDed.
 
 
diff --git a/hack/tools/go.mod b/hack/tools/go.mod
index 4c93029aa..84c6b1976 100644
--- a/hack/tools/go.mod
+++ b/hack/tools/go.mod
@@ -6,9 +6,8 @@ require (
 	github.com/a8m/envsubst v1.3.0
 	github.com/ahmetb/gen-crd-api-reference-docs v0.3.0
 	github.com/golang/mock v1.6.0
-	github.com/golangci/golangci-lint v1.44.2
+	github.com/golangci/golangci-lint v1.44.0
 	github.com/itchyny/gojq v0.12.6
-	github.com/joelanford/go-apidiff v0.2.0
 	github.com/onsi/ginkgo v1.16.5
 	github.com/spf13/pflag v1.0.5
 	k8s.io/apimachinery v0.23.0-alpha.4
@@ -47,10 +46,10 @@ require (
 	github.com/beorn7/perks v1.0.1 // indirect
 	github.com/bkielbasa/cyclop v1.2.0 // indirect
 	github.com/blang/semver v3.5.1+incompatible // indirect
-	github.com/blizzy78/varnamelen v0.6.0 // indirect
+	github.com/blizzy78/varnamelen v0.5.0 // indirect
 	github.com/bombsimon/wsl/v3 v3.3.0 // indirect
-	github.com/breml/bidichk v0.2.2 // indirect
-	github.com/breml/errchkjson v0.2.3 // indirect
+	github.com/breml/bidichk v0.2.1 // indirect
+	github.com/breml/errchkjson v0.2.1 // indirect
 	github.com/butuzov/ireturn v0.1.1 // indirect
 	github.com/census-instrumentation/opencensus-proto v0.3.0 // indirect
 	github.com/cespare/xxhash/v2 v2.1.2 // indirect
@@ -60,7 +59,7 @@ require (
 	github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4 // indirect
 	github.com/cncf/xds/go v0.0.0-20211130200136-a8f946100490 // indirect
 	github.com/containerd/stargz-snapshotter/estargz v0.7.0 // indirect
-	github.com/daixiang0/gci v0.3.1-0.20220208004058-76d765e3ab48 // indirect
+	github.com/daixiang0/gci v0.2.9 // indirect
 	github.com/davecgh/go-spew v1.1.1 // indirect
 	github.com/denis-tingajkin/go-header v0.4.2 // indirect
 	github.com/docker/cli v20.10.7+incompatible // indirect
@@ -114,7 +113,7 @@ require (
 	github.com/golangci/revgrep v0.0.0-20210930125155-c22e5001d4f2 // indirect
 	github.com/golangci/unconvert v0.0.0-20180507085042-28b1c447d1f4 // indirect
 	github.com/gomarkdown/markdown v0.0.0-20210514010506-3b9f47219fe7 // indirect
-	github.com/google/go-cmp v0.5.7 // indirect
+	github.com/google/go-cmp v0.5.6 // indirect
 	github.com/google/go-containerregistry v0.6.0 // indirect
 	github.com/google/go-github/v39 v39.2.0 // indirect
 	github.com/google/go-querystring v1.1.0 // indirect
@@ -131,7 +130,6 @@ require (
 	github.com/hashicorp/errwrap v1.0.0 // indirect
 	github.com/hashicorp/go-multierror v1.1.1 // indirect
 	github.com/hashicorp/hcl v1.0.0 // indirect
-	github.com/hexops/gotextdiff v1.0.3 // indirect
 	github.com/imdario/mergo v0.3.12 // indirect
 	github.com/in-toto/in-toto-golang v0.3.3 // indirect
 	github.com/inconshreveable/mousetrap v1.0.0 // indirect
@@ -147,11 +145,11 @@ require (
 	github.com/kisielk/errcheck v1.6.0 // indirect
 	github.com/kisielk/gotool v1.0.0 // indirect
 	github.com/klauspost/compress v1.13.5 // indirect
-	github.com/kulti/thelper v0.5.1 // indirect
+	github.com/kulti/thelper v0.5.0 // indirect
 	github.com/kunwardeep/paralleltest v1.0.3 // indirect
 	github.com/kyoh86/exportloopref v0.1.8 // indirect
 	github.com/ldez/gomoddirectives v0.2.2 // indirect
-	github.com/ldez/tagliatelle v0.3.1 // indirect
+	github.com/ldez/tagliatelle v0.3.0 // indirect
 	github.com/leonklingele/grouper v1.1.0 // indirect
 	github.com/magiconair/properties v1.8.5 // indirect
 	github.com/mailru/easyjson v0.7.6 // indirect
@@ -163,7 +161,7 @@ require (
 	github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 // indirect
 	github.com/mbilski/exhaustivestruct v1.2.0 // indirect
 	github.com/mgechev/dots v0.0.0-20210922191527-e955255bf517 // indirect
-	github.com/mgechev/revive v1.1.4 // indirect
+	github.com/mgechev/revive v1.1.3 // indirect
 	github.com/mitchellh/go-homedir v1.1.0 // indirect
 	github.com/mitchellh/mapstructure v1.4.3 // indirect
 	github.com/mmarkdown/mmark v2.0.40+incompatible // indirect
@@ -204,7 +202,7 @@ require (
 	github.com/sergi/go-diff v1.2.0 // indirect
 	github.com/shazow/go-diff v0.0.0-20160112020656-b6b7b6733b8c // indirect
 	github.com/shibumi/go-pathspec v1.2.0 // indirect
-	github.com/shirou/gopsutil/v3 v3.22.1 // indirect
+	github.com/shirou/gopsutil/v3 v3.21.12 // indirect
 	github.com/sirupsen/logrus v1.8.1 // indirect
 	github.com/sivchari/containedctx v1.0.1 // indirect
 	github.com/sivchari/tenv v1.4.7 // indirect
@@ -228,7 +226,7 @@ require (
 	github.com/tomarrell/wrapcheck/v2 v2.4.0 // indirect
 	github.com/tommy-muehle/go-mnd/v2 v2.5.0 // indirect
 	github.com/ultraware/funlen v0.0.3 // indirect
-	github.com/ultraware/whitespace v0.0.5 // indirect
+	github.com/ultraware/whitespace v0.0.4 // indirect
 	github.com/uudashr/gocognit v1.0.5 // indirect
 	github.com/xanzy/ssh-agent v0.3.0 // indirect
 	github.com/xlab/treeprint v0.0.0-20181112141820-a009c3971eca // indirect
@@ -239,15 +237,14 @@ require (
 	go.opencensus.io v0.23.0 // indirect
 	go.starlark.net v0.0.0-20200306205701-8dd3e2ee1dd5 // indirect
 	golang.org/x/crypto v0.0.0-20220112180741-5e0467b6c7ce // indirect
-	golang.org/x/exp v0.0.0-20211029160041-3396431c207b // indirect
 	golang.org/x/mod v0.6.0-dev.0.20211013180041-c96bc1413d57 // indirect
 	golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2 // indirect
 	golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8 // indirect
 	golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect
-	golang.org/x/sys v0.0.0-20220111092808-5a964db01320 // indirect
+	golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e // indirect
 	golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b // indirect
 	golang.org/x/text v0.3.7 // indirect
-	golang.org/x/tools v0.1.9 // indirect
+	golang.org/x/tools v0.1.9-0.20211228192929-ee1ca4ffc4da // indirect
 	golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect
 	google.golang.org/api v0.63.0 // indirect
 	google.golang.org/appengine v1.6.7 // indirect
diff --git a/hack/tools/go.sum b/hack/tools/go.sum
index 6739b0882..005489c25 100644
--- a/hack/tools/go.sum
+++ b/hack/tools/go.sum
@@ -210,16 +210,16 @@ github.com/bkielbasa/cyclop v1.2.0/go.mod h1:qOI0yy6A7dYC4Zgsa72Ppm9kONl0RoIlPbz
 github.com/blang/semver v3.1.0+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
 github.com/blang/semver v3.5.1+incompatible h1:cQNTCjp13qL8KC3Nbxr/y2Bqb63oX6wdnnjpJbkM4JQ=
 github.com/blang/semver v3.5.1+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
-github.com/blizzy78/varnamelen v0.6.0 h1:TOIDk9qRIMspALZKX8x+5hQfAjuvAFogppnxtvuNmBo=
-github.com/blizzy78/varnamelen v0.6.0/go.mod h1:zy2Eic4qWqjrxa60jG34cfL0VXcSwzUrIx68eJPb4Q8=
+github.com/blizzy78/varnamelen v0.5.0 h1:v9LpMwxzTqAJC4lsD/jR7zWb8a66trcqhTEH4Mk6Fio=
+github.com/blizzy78/varnamelen v0.5.0/go.mod h1:Mc0nLBKI1/FP0Ga4kqMOgBig0eS5QtR107JnMAb1Wuc=
 github.com/bmizerany/assert v0.0.0-20160611221934-b7ed37b82869/go.mod h1:Ekp36dRnpXw/yCqJaO+ZrUyxD+3VXMFFr56k5XYrpB4=
 github.com/bombsimon/wsl/v3 v3.0.0/go.mod h1:st10JtZYLE4D5sC7b8xV4zTKZwAQjCH/Hy2Pm1FNZIc=
 github.com/bombsimon/wsl/v3 v3.3.0 h1:Mka/+kRLoQJq7g2rggtgQsjuI/K5Efd87WX96EWFxjM=
 github.com/bombsimon/wsl/v3 v3.3.0/go.mod h1:st10JtZYLE4D5sC7b8xV4zTKZwAQjCH/Hy2Pm1FNZIc=
-github.com/breml/bidichk v0.2.2 h1:w7QXnpH0eCBJm55zGCTJveZEkQBt6Fs5zThIdA6qQ9Y=
-github.com/breml/bidichk v0.2.2/go.mod h1:zbfeitpevDUGI7V91Uzzuwrn4Vls8MoBMrwtt78jmso=
-github.com/breml/errchkjson v0.2.3 h1:97eGTmR/w0paL2SwfRPI1jaAZHaH/fXnxWTw2eEIqE0=
-github.com/breml/errchkjson v0.2.3/go.mod h1:jZEATw/jF69cL1iy7//Yih8yp/mXp2CBoBr9GJwCAsY=
+github.com/breml/bidichk v0.2.1 h1:SRNtZuLdfkxtocj+xyHXKC1Uv3jVi6EPYx+NHSTNQvE=
+github.com/breml/bidichk v0.2.1/go.mod h1:zbfeitpevDUGI7V91Uzzuwrn4Vls8MoBMrwtt78jmso=
+github.com/breml/errchkjson v0.2.1 h1:QCToXnY9BNngrbJoW3qfCTt3BdtbnsI6wyP/WGrxxSE=
+github.com/breml/errchkjson v0.2.1/go.mod h1:jZEATw/jF69cL1iy7//Yih8yp/mXp2CBoBr9GJwCAsY=
 github.com/bshuster-repo/logrus-logstash-hook v0.4.1/go.mod h1:zsTqEiSzDgAa/8GZR7E1qaXrhYNDKBYy5/dWPTIflbk=
 github.com/buger/jsonparser v0.0.0-20180808090653-f4dd9f5a6b44/go.mod h1:bbYlZJ7hK1yFx9hf58LP0zeX7UjIGs20ufpu3evjr+s=
 github.com/bugsnag/bugsnag-go v0.0.0-20141110184014-b1d153021fcd/go.mod h1:2oa8nejYd4cQ/b0hMIopN0lCRxU0bueqREvZLWFrtK8=
@@ -392,8 +392,8 @@ github.com/d2g/dhcp4 v0.0.0-20170904100407-a1d1b6c41b1c/go.mod h1:Ct2BUK8SB0YC1S
 github.com/d2g/dhcp4client v1.0.0/go.mod h1:j0hNfjhrt2SxUOw55nL0ATM/z4Yt3t2Kd1mW34z5W5s=
 github.com/d2g/dhcp4server v0.0.0-20181031114812-7d4a0a7f59a5/go.mod h1:Eo87+Kg/IX2hfWJfwxMzLyuSZyxSoAug2nGa1G2QAi8=
 github.com/d2g/hardwareaddr v0.0.0-20190221164911-e7d9fbe030e4/go.mod h1:bMl4RjIciD2oAxI7DmWRx6gbeqrkoLqv3MV0vzNad+I=
-github.com/daixiang0/gci v0.3.1-0.20220208004058-76d765e3ab48 h1:9rJGqaC5do9zkvKrtRdx0HJoxj7Jd6vDa0O2eBU0AbU=
-github.com/daixiang0/gci v0.3.1-0.20220208004058-76d765e3ab48/go.mod h1:jaASoJmv/ykO9dAAPy31iJnreV19248qKDdVWf3QgC4=
+github.com/daixiang0/gci v0.2.9 h1:iwJvwQpBZmMg31w+QQ6jsyZ54KEATn6/nfARbBNW294=
+github.com/daixiang0/gci v0.2.9/go.mod h1:+4dZ7TISfSmqfAGv59ePaHfNzgGtIkHAhhdKggP1JAc=
 github.com/davecgh/go-spew v0.0.0-20161028175848-04cdfd42973b/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
 github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
 github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
@@ -664,8 +664,8 @@ github.com/golangci/gocyclo v0.0.0-20180528134321-2becd97e67ee/go.mod h1:ozx7R9S
 github.com/golangci/gofmt v0.0.0-20190930125516-244bba706f1a h1:iR3fYXUjHCR97qWS8ch1y9zPNsgXThGwjKPrYfqMPks=
 github.com/golangci/gofmt v0.0.0-20190930125516-244bba706f1a/go.mod h1:9qCChq59u/eW8im404Q2WWTrnBUQKjpNYKMbU4M7EFU=
 github.com/golangci/golangci-lint v1.25.0/go.mod h1:BaJNZmLU6vdaTLEGJKTTL/05I3B2OfXaD9SrNVkwr7w=
-github.com/golangci/golangci-lint v1.44.2 h1:MzvkDt1j1OHkv42/feNJVNNXRFACPp7aAWBWDo5aYQw=
-github.com/golangci/golangci-lint v1.44.2/go.mod h1:KjBgkLvsTWDkhfu12iCrv0gwL1kON5KNhbyjQ6qN7Jo=
+github.com/golangci/golangci-lint v1.44.0 h1:YJPouGNQEdK+x2KsCpWMIBy0q6MSuxHjkWMxJMNj/DU=
+github.com/golangci/golangci-lint v1.44.0/go.mod h1:aBolpzNkmYogKPynGKdOWDCEc8LlwnxZC6w/SJ1TaEs=
 github.com/golangci/ineffassign v0.0.0-20190609212857-42439a7714cc/go.mod h1:e5tpTHCfVze+7EpLEozzMB3eafxo2KT5veNg1k6byQU=
 github.com/golangci/lint-1 v0.0.0-20191013205115-297bf364a8e0 h1:MfyDlzVjl1hoaPzPD4Gpb/QgoRfSBR0jdhwGyAWwMSA=
 github.com/golangci/lint-1 v0.0.0-20191013205115-297bf364a8e0/go.mod h1:66R6K6P6VWk9I95jvqGxkqJxVWGFy9XlDwLwVz1RCFg=
@@ -698,9 +698,8 @@ github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/
 github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
 github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
 github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
 github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
-github.com/google/go-cmp v0.5.7 h1:81/ik6ipDQS2aGcBfIN5dHDB36BwrStyeAQquSYCV4o=
-github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8/DtOE=
 github.com/google/go-containerregistry v0.6.0 h1:niQ+8XD//kKgArIFwDVBXsWVWbde16LPdHMyNwSC8h4=
 github.com/google/go-containerregistry v0.6.0/go.mod h1:euCCtNbZ6tKqi1E72vwDj2xZcN5ttKpZLfa/wSo5iLw=
 github.com/google/go-github/v33 v33.0.0/go.mod h1:GMdDnVZY/2TsWgp/lkYnpSAh6TrzhANBBwm6k6TTEXg=
@@ -856,8 +855,6 @@ github.com/hashicorp/memberlist v0.3.0/go.mod h1:MS2lj3INKhZjWNqd3N0m3J+Jxf3DAOn
 github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc=
 github.com/hashicorp/serf v0.9.5/go.mod h1:UWDWwZeL5cuWDJdl0C6wrvrUwEqtQ4ZKBKKENpqIUyk=
 github.com/hashicorp/serf v0.9.6/go.mod h1:TXZNMjZQijwlDvp+r0b63xZ45H7JmCmgg4gpTwn9UV4=
-github.com/hexops/gotextdiff v1.0.3 h1:gitA9+qJrrTCsiCl7+kh75nPqQt1cx4ZkudSTLoUqJM=
-github.com/hexops/gotextdiff v1.0.3/go.mod h1:pSWU5MAI3yDq+fZBTazCSJysOMbxWL1BSow5/V2vxeg=
 github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU=
 github.com/huandu/xstrings v1.0.0/go.mod h1:4qWG/gcEcfX4z/mBDHJ++3ReCw9ibxbsNJbcucJdbSo=
 github.com/huandu/xstrings v1.2.0/go.mod h1:DvyZB1rfVYsBIigL8HwpZgxHwXozlTgGqn63UyNX5k4=
@@ -905,8 +902,6 @@ github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfC
 github.com/jmoiron/sqlx v1.2.0/go.mod h1:1FEQNm3xlJgrMD+FBdI9+xvCksHtbpVBBw5dYhBSsks=
 github.com/jmoiron/sqlx v1.2.1-0.20190826204134-d7d95172beb5/go.mod h1:1FEQNm3xlJgrMD+FBdI9+xvCksHtbpVBBw5dYhBSsks=
 github.com/joelanford/go-apidiff v0.1.0/go.mod h1:wgVWgVCwYYkjcYpJtBnWYkyUYZfVovO3Y5pX49mJsqs=
-github.com/joelanford/go-apidiff v0.2.0 h1:qChl0utb9SUk8K1XYjxd0uamfSPELIgleS0Ve5RggKs=
-github.com/joelanford/go-apidiff v0.2.0/go.mod h1:46ufX9MyC2TmG+kCfwCB+Yxu19l7WN+4CN/flWAJ2v8=
 github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo=
 github.com/jonboulle/clockwork v0.2.0/go.mod h1:Pkfl5aHPm1nk2H9h0bjmnJD/BcgbGXUBGnn1kMkgxc8=
 github.com/jonboulle/clockwork v0.2.2/go.mod h1:Pkfl5aHPm1nk2H9h0bjmnJD/BcgbGXUBGnn1kMkgxc8=
@@ -971,8 +966,8 @@ github.com/kr/pty v1.1.8/go.mod h1:O1sed60cT9XZ5uDucP5qwvh+TE3NnUj51EiZO/lmSfw=
 github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
 github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
 github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
-github.com/kulti/thelper v0.5.1 h1:Uf4CUekH0OvzQTFPrWkstJvXgm6pnNEtQu3HiqEkpB0=
-github.com/kulti/thelper v0.5.1/go.mod h1:vMu2Cizjy/grP+jmsvOFDx1kYP6+PD1lqg4Yu5exl2U=
+github.com/kulti/thelper v0.5.0 h1:CiEKStgoG4K9bjf/zk3eNX0D0J2iFWzxEY+h9UXmlJg=
+github.com/kulti/thelper v0.5.0/go.mod h1:vMu2Cizjy/grP+jmsvOFDx1kYP6+PD1lqg4Yu5exl2U=
 github.com/kunwardeep/paralleltest v1.0.3 h1:UdKIkImEAXjR1chUWLn+PNXqWUGs//7tzMeWuP7NhmI=
 github.com/kunwardeep/paralleltest v1.0.3/go.mod h1:vLydzomDFpk7yu5UX02RmP0H8QfRPOV/oFhWN85Mjb4=
 github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw=
@@ -980,8 +975,8 @@ github.com/kyoh86/exportloopref v0.1.8 h1:5Ry/at+eFdkX9Vsdw3qU4YkvGtzuVfzT4X7S77
 github.com/kyoh86/exportloopref v0.1.8/go.mod h1:1tUcJeiioIs7VWe5gcOObrux3lb66+sBqGZrRkMwPgg=
 github.com/ldez/gomoddirectives v0.2.2 h1:p9/sXuNFArS2RLc+UpYZSI4KQwGMEDWC/LbtF5OPFVg=
 github.com/ldez/gomoddirectives v0.2.2/go.mod h1:cpgBogWITnCfRq2qGoDkKMEVSaarhdBr6g8G04uz6d0=
-github.com/ldez/tagliatelle v0.3.1 h1:3BqVVlReVUZwafJUwQ+oxbx2BEX2vUG4Yu/NOfMiKiM=
-github.com/ldez/tagliatelle v0.3.1/go.mod h1:8s6WJQwEYHbKZDsp/LjArytKOG8qaMrKQQ3mFukHs88=
+github.com/ldez/tagliatelle v0.3.0 h1:Aubm2ZsrsjIGFvdxemMPJaXrSJ5Cys6VWyTQFt9k2dI=
+github.com/ldez/tagliatelle v0.3.0/go.mod h1:8s6WJQwEYHbKZDsp/LjArytKOG8qaMrKQQ3mFukHs88=
 github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII=
 github.com/leonklingele/grouper v1.1.0 h1:tC2y/ygPbMFSBOs3DcyaEMKnnwH7eYKzohOtRrf0SAg=
 github.com/leonklingele/grouper v1.1.0/go.mod h1:uk3I3uDfi9B6PeUjsCKi6ndcf63Uy7snXgR4yDYQVDY=
@@ -1052,8 +1047,8 @@ github.com/mbilski/exhaustivestruct v1.2.0 h1:wCBmUnSYufAHO6J4AVWY6ff+oxWxsVFrwg
 github.com/mbilski/exhaustivestruct v1.2.0/go.mod h1:OeTBVxQWoEmB2J2JCHmXWPJ0aksxSUOUy+nvtVEfzXc=
 github.com/mgechev/dots v0.0.0-20210922191527-e955255bf517 h1:zpIH83+oKzcpryru8ceC6BxnoG8TBrhgAvRg8obzup0=
 github.com/mgechev/dots v0.0.0-20210922191527-e955255bf517/go.mod h1:KQ7+USdGKfpPjXk4Ga+5XxQM4Lm4e3gAogrreFAYpOg=
-github.com/mgechev/revive v1.1.4 h1:sZOjY6GU35Kr9jKa/wsKSHgrFz8eASIB5i3tqWZMp0A=
-github.com/mgechev/revive v1.1.4/go.mod h1:ZZq2bmyssGh8MSPz3VVziqRNIMYTJXzP8MUKG90vZ9A=
+github.com/mgechev/revive v1.1.3 h1:6tBZacs2/uv9UOpkBQhCtXh2NGgu2Ry97ZyjcN6uDCM=
+github.com/mgechev/revive v1.1.3/go.mod h1:jMzDa13teAuv/KLeqgJw79NDe+1IT0ZO3Mht0vN1Yls=
 github.com/mholt/archiver/v3 v3.5.0/go.mod h1:qqTTPUK/HZPFgFQ/TJ3BzvTpF/dPtFVJXdQbCmeMxwc=
 github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg=
 github.com/miekg/dns v1.1.26/go.mod h1:bPDLeHnStXmXAq1m/Ch/hvfNHr14JKNPMBo3VZKjuso=
@@ -1309,7 +1304,7 @@ github.com/quasilyte/go-ruleguard v0.3.15/go.mod h1:NhuWhnlVEM1gT1A4VJHYfy9MuYSx
 github.com/quasilyte/go-ruleguard/dsl v0.3.0/go.mod h1:KeCP03KrjuSO0H1kTuZQCWlQPulDV6YMIXmpQss17rU=
 github.com/quasilyte/go-ruleguard/dsl v0.3.12-0.20220101150716-969a394a9451/go.mod h1:KeCP03KrjuSO0H1kTuZQCWlQPulDV6YMIXmpQss17rU=
 github.com/quasilyte/go-ruleguard/dsl v0.3.12/go.mod h1:KeCP03KrjuSO0H1kTuZQCWlQPulDV6YMIXmpQss17rU=
-github.com/quasilyte/go-ruleguard/dsl v0.3.17/go.mod h1:KeCP03KrjuSO0H1kTuZQCWlQPulDV6YMIXmpQss17rU=
+github.com/quasilyte/go-ruleguard/dsl v0.3.15/go.mod h1:KeCP03KrjuSO0H1kTuZQCWlQPulDV6YMIXmpQss17rU=
 github.com/quasilyte/go-ruleguard/rules v0.0.0-20201231183845-9e62ed36efe1/go.mod h1:7JTjp89EGyU1d6XfBiXihJNG37wB2VRkd125Q1u7Plc=
 github.com/quasilyte/go-ruleguard/rules v0.0.0-20211022131956-028d6511ab71/go.mod h1:4cgAphtvu7Ftv7vOT2ZOYhC6CvBxZixcasr8qIOTA50=
 github.com/quasilyte/gogrep v0.0.0-20220103110004-ffaa07af02e3 h1:P4QPNn+TK49zJjXKERt/vyPbv/mCHB/zQ4flDYOMN+M=
@@ -1371,8 +1366,8 @@ github.com/shibumi/go-pathspec v1.2.0/go.mod h1:bDxCftD0fST3qXIlHoQ/fChsU4mWMVkl
 github.com/shirou/gopsutil v0.0.0-20190901111213-e4ec7b275ada h1:WokF3GuxBeL+n4Lk4Fa8v9mbdjlrl7bHuneF4N1bk2I=
 github.com/shirou/gopsutil v0.0.0-20190901111213-e4ec7b275ada/go.mod h1:WWnYX4lzhCH5h/3YBfyVA3VbLYjlMZZAQcW9ojMexNc=
 github.com/shirou/gopsutil/v3 v3.21.10/go.mod h1:t75NhzCZ/dYyPQjyQmrAYP6c8+LCdFANeBMdLPCNnew=
-github.com/shirou/gopsutil/v3 v3.22.1 h1:33y31Q8J32+KstqPfscvFwBlNJ6xLaBy4xqBXzlYV5w=
-github.com/shirou/gopsutil/v3 v3.22.1/go.mod h1:WapW1AOOPlHyXr+yOyw3uYx36enocrtSoSBy0L5vUHY=
+github.com/shirou/gopsutil/v3 v3.21.12 h1:VoGxEW2hpmz0Vt3wUvHIl9fquzYLNpVpgNNB7pGJimA=
+github.com/shirou/gopsutil/v3 v3.21.12/go.mod h1:BToYZVTlSVlfazpDDYFnsVZLaoRG+g8ufT6fPQLdJzA=
 github.com/shirou/w32 v0.0.0-20160930032740-bb4de0191aa4/go.mod h1:qsXQc7+bwAM3Q1u/4XEfrquwF8Lw7D7y5cD8CuHnfIc=
 github.com/shurcooL/go v0.0.0-20180423040247-9e1955d9fb6e/go.mod h1:TDJrrUr11Vxrven61rcy3hJMUqaf/CLWYhHNPmT14Lk=
 github.com/shurcooL/go-goon v0.0.0-20170922171312-37c2f522c041/go.mod h1:N5mDOmsrJOB+vfqUK+7DmDyjhSLIIBnXo9lvZJj3MWQ=
@@ -1509,9 +1504,8 @@ github.com/ulikunitz/xz v0.5.7/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oW
 github.com/ultraware/funlen v0.0.2/go.mod h1:Dp4UiAus7Wdb9KUZsYWZEWiRzGuM2kXM1lPbfaF6xhA=
 github.com/ultraware/funlen v0.0.3 h1:5ylVWm8wsNwH5aWo9438pwvsK0QiqVuUrt9bn7S/iLA=
 github.com/ultraware/funlen v0.0.3/go.mod h1:Dp4UiAus7Wdb9KUZsYWZEWiRzGuM2kXM1lPbfaF6xhA=
+github.com/ultraware/whitespace v0.0.4 h1:If7Va4cM03mpgrNH9k49/VOicWpGoG70XPBFFODYDsg=
 github.com/ultraware/whitespace v0.0.4/go.mod h1:aVMh/gQve5Maj9hQ/hg+F75lr/X5A89uZnzAmWSineA=
-github.com/ultraware/whitespace v0.0.5 h1:hh+/cpIcopyMYbZNVov9iSxvJU3OYQg78Sfaqzi/CzI=
-github.com/ultraware/whitespace v0.0.5/go.mod h1:aVMh/gQve5Maj9hQ/hg+F75lr/X5A89uZnzAmWSineA=
 github.com/urfave/cli v0.0.0-20171014202726-7bc6a0acffa5/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
 github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
 github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0=
@@ -1678,7 +1672,6 @@ golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u0
 golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM=
 golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU=
 golang.org/x/exp v0.0.0-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw=
-golang.org/x/exp v0.0.0-20211029160041-3396431c207b h1:58UzImHd/vC6WxTQm75bwlBAOU/jDjzIMHUGO8O65UM=
 golang.org/x/exp v0.0.0-20211029160041-3396431c207b/go.mod h1:OyI624f2tQ/aU3IMa7GB16Hk54CHURAfHfj6tMqtyhA=
 golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
 golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
@@ -1941,9 +1934,8 @@ golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBc
 golang.org/x/sys v0.0.0-20211205182925-97ca703d548d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
 golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
 golang.org/x/sys v0.0.0-20211213223007-03aa0b5f6827/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e h1:fLOSk5Q00efkSvAm+4xcoXD+RRmLmmulPn5I3Y9F2EM=
 golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.0.0-20220111092808-5a964db01320 h1:0jf+tOCoZ3LyutmCOWpVni1chK4VfFLhRsDK7MhqGRY=
-golang.org/x/sys v0.0.0-20220111092808-5a964db01320/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
 golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
 golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
 golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b h1:9zKuko04nR4gjZ4+DNjHqRlAJqbJETHwiNKDqTfOjfE=
@@ -2063,6 +2055,7 @@ golang.org/x/tools v0.0.0-20201023174141-c8cfbd0f21e6/go.mod h1:emZCQorbCU4vsT4f
 golang.org/x/tools v0.0.0-20201028025901-8cd080b735b3/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
 golang.org/x/tools v0.0.0-20201110124207-079ba7bd75cd/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
 golang.org/x/tools v0.0.0-20201114224030-61ea331ec02b/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
+golang.org/x/tools v0.0.0-20201118003311-bd56c0adb394/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
 golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
 golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
 golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
@@ -2081,9 +2074,8 @@ golang.org/x/tools v0.1.6-0.20210820212750-d4cc65f0b2ff/go.mod h1:YD9qOF0M9xpSpd
 golang.org/x/tools v0.1.7/go.mod h1:LGqMHiF4EqQNHR1JncWGqT5BVaXmza+X+BDGol+dOxo=
 golang.org/x/tools v0.1.8-0.20211029000441-d6a9af8af023/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU=
 golang.org/x/tools v0.1.8/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU=
+golang.org/x/tools v0.1.9-0.20211228192929-ee1ca4ffc4da h1:Tno72dYE94v/7SyyIj9iBsc7OOjFu2PyNcl7yxxeZD8=
 golang.org/x/tools v0.1.9-0.20211228192929-ee1ca4ffc4da/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU=
-golang.org/x/tools v0.1.9 h1:j9KsMiaP1c3B0OTQGth0/k+miLGTgLsAFUCrF2vLcF8=
-golang.org/x/tools v0.1.9/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU=
 golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
 golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
 golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
diff --git a/hack/tools/tools.go b/hack/tools/tools.go
index b3eda5780..688bc44c1 100644
--- a/hack/tools/tools.go
+++ b/hack/tools/tools.go
@@ -28,7 +28,6 @@ import (
 	_ "github.com/golang/mock/mockgen"
 	_ "github.com/golangci/golangci-lint/cmd/golangci-lint"
 	_ "github.com/itchyny/gojq/cmd/gojq"
-	_ "github.com/joelanford/go-apidiff"
 	_ "github.com/onsi/ginkgo/ginkgo"
 	_ "k8s.io/apimachinery/pkg/util/intstr"
 	_ "k8s.io/code-generator"
diff --git a/pkg/cloud/scope/cluster.go b/pkg/cloud/scope/cluster.go
index 74dea1622..55d09b50a 100644
--- a/pkg/cloud/scope/cluster.go
+++ b/pkg/cloud/scope/cluster.go
@@ -193,10 +193,6 @@ func (s *ClusterScope) ControlPlaneLoadBalancerName() *string {
 	return nil
 }
 
-func (s *ClusterScope) ControlPlaneEndpoint() clusterv1.APIEndpoint {
-	return s.AWSCluster.Spec.ControlPlaneEndpoint
-}
-
 // ControlPlaneConfigMapName returns the name of the ConfigMap used to
 // coordinate the bootstrapping of control plane nodes.
 func (s *ClusterScope) ControlPlaneConfigMapName() string {
diff --git a/pkg/cloud/scope/elb.go b/pkg/cloud/scope/elb.go
index 5bd33eb52..2f42120fb 100644
--- a/pkg/cloud/scope/elb.go
+++ b/pkg/cloud/scope/elb.go
@@ -19,7 +19,6 @@ package scope
 import (
 	infrav1 "sigs.k8s.io/cluster-api-provider-aws/api/v1beta1"
 	"sigs.k8s.io/cluster-api-provider-aws/pkg/cloud"
-	clusterv1 "sigs.k8s.io/cluster-api/api/v1beta1"
 )
 
 // ELBScope is a scope for use with the ELB reconciling service.
@@ -46,7 +45,4 @@ type ELBScope interface {
 
 	// ControlPlaneLoadBalancerName returns the Classic ELB name
 	ControlPlaneLoadBalancerName() *string
-
-	// ControlPlaneEndpoint returns AWSCluster control plane endpoint
-	ControlPlaneEndpoint() clusterv1.APIEndpoint
 }
diff --git a/pkg/cloud/scope/managedcontrolplane.go b/pkg/cloud/scope/managedcontrolplane.go
index 42d849851..a09fd5f2a 100644
--- a/pkg/cloud/scope/managedcontrolplane.go
+++ b/pkg/cloud/scope/managedcontrolplane.go
@@ -231,7 +231,6 @@ func (s *ManagedControlPlaneScope) PatchObject() error {
 		patch.WithOwnedConditions{Conditions: []clusterv1.ConditionType{
 			infrav1.VpcReadyCondition,
 			infrav1.SubnetsReadyCondition,
-			infrav1.ClusterSecurityGroupsReadyCondition,
 			infrav1.InternetGatewayReadyCondition,
 			infrav1.NatGatewaysReadyCondition,
 			infrav1.RouteTablesReadyCondition,
diff --git a/pkg/cloud/services/elb/loadbalancer.go b/pkg/cloud/services/elb/loadbalancer.go
index d25563f22..50252e597 100644
--- a/pkg/cloud/services/elb/loadbalancer.go
+++ b/pkg/cloud/services/elb/loadbalancer.go
@@ -77,17 +77,14 @@ func (s *Service) ReconcileLoadbalancers() error {
 	}
 
 	apiELB, err := s.describeClassicELB(spec.Name)
-	switch {
-	case IsNotFound(err) && s.scope.ControlPlaneEndpoint().IsValid():
-		// if elb is not found and owner cluster ControlPlaneEndpoint is already populated, then we should not recreate the elb.
-		return errors.Wrapf(err, "no loadbalancer exists for the AWSCluster %s, the cluster has become unrecoverable and should be deleted manually", s.scope.InfraClusterName())
-	case IsNotFound(err):
+	if IsNotFound(err) {
 		apiELB, err = s.createClassicELB(spec)
 		if err != nil {
 			return err
 		}
+
 		s.scope.V(2).Info("Created new classic load balancer for apiserver", "api-server-elb-name", apiELB.Name)
-	case err != nil:
+	} else if err != nil {
 		// Failed to describe the classic ELB
 		return err
 	}
@@ -434,7 +431,7 @@ func (s *Service) getAPIServerClassicELBSpec(elbName string) (*infrav1.ClassicEL
 			},
 		},
 		HealthCheck: &infrav1.ClassicELBHealthCheck{
-			Target:             fmt.Sprintf("%v:%d", s.getHealthCheckELBProtocol(), 6443),
+			Target:             fmt.Sprintf("%v:%d", infrav1.ClassicELBProtocolSSL, 6443),
 			Interval:           10 * time.Second,
 			Timeout:            5 * time.Second,
 			HealthyThreshold:   5,
@@ -784,14 +781,6 @@ func (s *Service) reconcileELBTags(lb *infrav1.ClassicELB, desiredTags map[strin
 	return nil
 }
 
-func (s *Service) getHealthCheckELBProtocol() *infrav1.ClassicELBProtocol {
-	controlPlaneELB := s.scope.ControlPlaneLoadBalancer()
-	if controlPlaneELB != nil && controlPlaneELB.HealthCheckProtocol != nil {
-		return controlPlaneELB.HealthCheckProtocol
-	}
-	return &infrav1.ClassicELBProtocolSSL
-}
-
 func fromSDKTypeToClassicELB(v *elb.LoadBalancerDescription, attrs *elb.LoadBalancerAttributes, tags []*elb.Tag) *infrav1.ClassicELB {
 	res := &infrav1.ClassicELB{
 		Name:             aws.StringValue(v.LoadBalancerName),
diff --git a/pkg/cloud/services/network/secondarycidr.go b/pkg/cloud/services/network/secondarycidr.go
index 3d663a31d..aad203709 100644
--- a/pkg/cloud/services/network/secondarycidr.go
+++ b/pkg/cloud/services/network/secondarycidr.go
@@ -17,12 +17,18 @@ limitations under the License.
 package network
 
 import (
+	"reflect"
+
 	"github.com/aws/aws-sdk-go/service/ec2"
 	"github.com/pkg/errors"
 
 	"sigs.k8s.io/cluster-api-provider-aws/pkg/record"
 )
 
+func isVPCPresent(vpcs *ec2.DescribeVpcsOutput) bool {
+	return vpcs != nil && len(vpcs.Vpcs) > 0
+}
+
 func (s *Service) associateSecondaryCidr() error {
 	if s.scope.SecondaryCidrBlock() == nil {
 		return nil
@@ -35,8 +41,8 @@ func (s *Service) associateSecondaryCidr() error {
 		return err
 	}
 
-	if len(vpcs.Vpcs) != 1 {
-		return errors.Errorf("VPC not found")
+	if !isVPCPresent(vpcs) {
+		return errors.Errorf("failed to associateSecondaryCidr as there are no VPCs present")
 	}
 
 	existingAssociations := vpcs.Vpcs[0].CidrBlockAssociationSet
@@ -55,6 +61,7 @@ func (s *Service) associateSecondaryCidr() error {
 		return err
 	}
 
+	// once IPv6 is supported, we need to modify out.CidrBlockAssociation.AssociationId to out.Ipv6CidrBlockAssociation.AssociationId
 	record.Eventf(s.scope.InfraCluster(), "SuccessfulAssociateSecondaryCidr", "Associated secondary CIDR with VPC %q", *out.CidrBlockAssociation.AssociationId)
 
 	return nil
@@ -72,17 +79,16 @@ func (s *Service) disassociateSecondaryCidr() error {
 		return err
 	}
 
-	if len(vpcs.Vpcs) != 1 {
-		return errors.Errorf("VPC not found")
+	if !isVPCPresent(vpcs) {
+		return errors.Errorf("failed to associateSecondaryCidr as there are no VPCs present")
 	}
 
 	existingAssociations := vpcs.Vpcs[0].CidrBlockAssociationSet
 	for _, existing := range existingAssociations {
-		if existing.CidrBlock == s.scope.SecondaryCidrBlock() {
-			_, err := s.EC2Client.DisassociateVpcCidrBlock(&ec2.DisassociateVpcCidrBlockInput{
+		if reflect.DeepEqual(existing.CidrBlock, s.scope.SecondaryCidrBlock()) {
+			if _, err := s.EC2Client.DisassociateVpcCidrBlock(&ec2.DisassociateVpcCidrBlockInput{
 				AssociationId: existing.AssociationId,
-			})
-			if err != nil {
+			}); err != nil {
 				record.Warnf(s.scope.InfraCluster(), "FailedDisassociateSecondaryCidr", "Failed disassociating secondary CIDR with VPC %v", err)
 				return err
 			}
diff --git a/pkg/hash/base36.go b/pkg/hash/base36.go
index 32d3475cd..9965a0e7c 100644
--- a/pkg/hash/base36.go
+++ b/pkg/hash/base36.go
@@ -19,7 +19,9 @@ package hash
 import (
 	"github.com/pkg/errors"
 	"golang.org/x/crypto/blake2b"
-	_ "k8s.io/apimachinery/pkg/util/intstr" // keep the blank import to include intstr.
+
+	// keep the blank import to include intstr.
+	_ "k8s.io/apimachinery/pkg/util/intstr"
 )
 
 const base36set = "0123456789abcdefghijklmnopqrstuvwxyz"
diff --git a/scripts/ci-apidiff.sh b/scripts/ci-apidiff.sh
index 1e9e04145..01e0d286b 100755
--- a/scripts/ci-apidiff.sh
+++ b/scripts/ci-apidiff.sh
@@ -19,9 +19,10 @@ set -o nounset
 set -o pipefail
 
 REPO_ROOT=$(dirname "${BASH_SOURCE[0]}")/..
-APIDIFF="${REPO_ROOT}/hack/tools/bin/go-apidiff"
 
-cd "${REPO_ROOT}" && make apidiff
+APIDIFF="hack/tools/bin/go-apidiff"
+
+cd "${REPO_ROOT}" && make ${APIDIFF}
 echo "*** Running go-apidiff ***"
 
 ${APIDIFF} "${PULL_BASE_SHA}" --print-compatible
diff --git a/tilt-provider.json b/tilt-provider.json
index fd95bfb3d..d89648e4e 100644
--- a/tilt-provider.json
+++ b/tilt-provider.json
@@ -15,7 +15,8 @@
         "controlplane/eks",
         "bootstrap/eks"
       ],
-      "label": "CAPA"
+      "label": "CAPA",
+      "manager_name": "capa-controller-manager"
     }
   }
 ]


Test patch:
diff --git a/api/v1beta1/awscluster_webhook_test.go b/api/v1beta1/awscluster_webhook_test.go
index 42614b3fb..ed776473a 100644
--- a/api/v1beta1/awscluster_webhook_test.go
+++ b/api/v1beta1/awscluster_webhook_test.go
@@ -46,7 +46,7 @@ func TestAWSCluster_ValidateCreate(t *testing.T) {
 		name    string
 		cluster *AWSCluster
 		wantErr bool
-		expect  func(g *WithT, res *AWSLoadBalancerSpec)
+		expect  func(t *testing.T, res *AWSLoadBalancerSpec)
 	}{
 		// The SSHKeyName tests were moved to sshkeyname_test.go
 		{
@@ -54,8 +54,12 @@ func TestAWSCluster_ValidateCreate(t *testing.T) {
 			cluster: &AWSCluster{
 				Spec: AWSClusterSpec{},
 			},
-			expect: func(g *WithT, res *AWSLoadBalancerSpec) {
-				g.Expect(res.Scheme.String(), ClassicELBSchemeInternetFacing.String())
+			expect: func(t *testing.T, res *AWSLoadBalancerSpec) {
+				t.Helper()
+
+				if res.Scheme.String() != ClassicELBSchemeInternetFacing.String() {
+					t.Error("Expected internet-facing defaulting for nil loadbalancer schemes")
+				}
 			},
 			wantErr: false,
 		},
@@ -66,8 +70,12 @@ func TestAWSCluster_ValidateCreate(t *testing.T) {
 					ControlPlaneLoadBalancer: &AWSLoadBalancerSpec{Scheme: &ClassicELBSchemeIncorrectInternetFacing},
 				},
 			},
-			expect: func(g *WithT, res *AWSLoadBalancerSpec) {
-				g.Expect(res.Scheme.String(), ClassicELBSchemeInternetFacing.String())
+			expect: func(t *testing.T, res *AWSLoadBalancerSpec) {
+				t.Helper()
+
+				if res.Scheme.String() != ClassicELBSchemeInternetFacing.String() {
+					t.Error("Expected internet-facing defaulting for supported incorrect scheme: Internet-facing")
+				}
 			},
 			wantErr: false,
 		},
@@ -123,7 +131,7 @@ func TestAWSCluster_ValidateCreate(t *testing.T) {
 				return err == nil
 			}, 10*time.Second).Should(Equal(true))
 
-			tt.expect(g, c.Spec.ControlPlaneLoadBalancer)
+			tt.expect(t, c.Spec.ControlPlaneLoadBalancer)
 		})
 	}
 }
@@ -360,56 +368,6 @@ func TestAWSCluster_ValidateUpdate(t *testing.T) {
 			},
 			wantErr: true,
 		},
-		{
-			name: "Should fail if controlPlaneLoadBalancer healthcheckprotocol is updated",
-			oldCluster: &AWSCluster{
-				Spec: AWSClusterSpec{
-					ControlPlaneLoadBalancer: &AWSLoadBalancerSpec{
-						HealthCheckProtocol: &ClassicELBProtocolTCP,
-					},
-				},
-			},
-			newCluster: &AWSCluster{
-				Spec: AWSClusterSpec{
-					ControlPlaneLoadBalancer: &AWSLoadBalancerSpec{
-						HealthCheckProtocol: &ClassicELBProtocolSSL,
-					},
-				},
-			},
-			wantErr: true,
-		},
-		{
-			name: "Should pass if controlPlaneLoadBalancer healthcheckprotocol is same after update",
-			oldCluster: &AWSCluster{
-				Spec: AWSClusterSpec{
-					ControlPlaneLoadBalancer: &AWSLoadBalancerSpec{
-						HealthCheckProtocol: &ClassicELBProtocolTCP,
-					},
-				},
-			},
-			newCluster: &AWSCluster{
-				Spec: AWSClusterSpec{
-					ControlPlaneLoadBalancer: &AWSLoadBalancerSpec{
-						HealthCheckProtocol: &ClassicELBProtocolTCP,
-					},
-				},
-			},
-			wantErr: false,
-		},
-		{
-			name: "Should fail if controlPlaneLoadBalancer healthcheckprotocol is changed to non-default if it was not set before update",
-			oldCluster: &AWSCluster{
-				Spec: AWSClusterSpec{},
-			},
-			newCluster: &AWSCluster{
-				Spec: AWSClusterSpec{
-					ControlPlaneLoadBalancer: &AWSLoadBalancerSpec{
-						HealthCheckProtocol: &ClassicELBProtocolTCP,
-					},
-				},
-			},
-			wantErr: true,
-		},
 	}
 	for _, tt := range tests {
 		t.Run(tt.name, func(t *testing.T) {
diff --git a/exp/controlleridentitycreator/awscontrolleridentity_controller_test.go b/exp/controlleridentitycreator/awscontrolleridentity_controller_test.go
index f78f9e971..a9b9cef48 100644
--- a/exp/controlleridentitycreator/awscontrolleridentity_controller_test.go
+++ b/exp/controlleridentitycreator/awscontrolleridentity_controller_test.go
@@ -29,8 +29,8 @@ import (
 	infrav1 "sigs.k8s.io/cluster-api-provider-aws/api/v1beta1"
 )
 
-func TestAWSControllerIdentityController(t *testing.T) {
-	t.Run("should create AWSClusterControllerIdentity when identityRef is not specified", func(t *testing.T) {
+func TestAWSInstanceStateController(t *testing.T) {
+	t.Run("should maintain list of cluster queue URLs and reconcile failing machines", func(t *testing.T) {
 		g := NewWithT(t)
 		ctx := context.Background()
 
diff --git a/exp/controllers/awsmachinepool_controller_test.go b/exp/controllers/awsmachinepool_controller_test.go
index 9f14f8cee..87108ff5f 100644
--- a/exp/controllers/awsmachinepool_controller_test.go
+++ b/exp/controllers/awsmachinepool_controller_test.go
@@ -42,6 +42,8 @@ import (
 	"sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/services/mock_services"
 	clusterv1 "sigs.k8s.io/cluster-api/api/v1beta1"
 	"sigs.k8s.io/cluster-api/controllers/noderefutil"
+
+	// "sigs.k8s.io/cluster-api/controllers/noderefutil" //nolint:godot.
 	capierrors "sigs.k8s.io/cluster-api/errors"
 	expclusterv1 "sigs.k8s.io/cluster-api/exp/api/v1beta1"
 	"sigs.k8s.io/cluster-api/util/conditions"
diff --git a/pkg/cloud/services/elb/loadbalancer_test.go b/pkg/cloud/services/elb/loadbalancer_test.go
index 416252dbe..556e392d8 100644
--- a/pkg/cloud/services/elb/loadbalancer_test.go
+++ b/pkg/cloud/services/elb/loadbalancer_test.go
@@ -28,7 +28,6 @@ import (
 	"github.com/aws/aws-sdk-go/service/elb"
 	rgapi "github.com/aws/aws-sdk-go/service/resourcegroupstaggingapi"
 	"github.com/golang/mock/gomock"
-	. "github.com/onsi/gomega"
 	"github.com/pkg/errors"
 	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
 	"k8s.io/apimachinery/pkg/runtime"
@@ -155,13 +154,13 @@ func TestGetAPIServerClassicELBSpec_ControlPlaneLoadBalancer(t *testing.T) {
 		name   string
 		lb     *infrav1.AWSLoadBalancerSpec
 		mocks  func(m *mock_ec2iface.MockEC2APIMockRecorder)
-		expect func(t *testing.T, g *WithT, res *infrav1.ClassicELB)
+		expect func(t *testing.T, res *infrav1.ClassicELB)
 	}{
 		{
 			name:  "nil load balancer config",
 			lb:    nil,
 			mocks: func(m *mock_ec2iface.MockEC2APIMockRecorder) {},
-			expect: func(t *testing.T, g *WithT, res *infrav1.ClassicELB) {
+			expect: func(t *testing.T, res *infrav1.ClassicELB) {
 				t.Helper()
 				if res.Attributes.CrossZoneLoadBalancing {
 					t.Error("Expected load balancer not to have cross-zone load balancing enabled")
@@ -174,7 +173,7 @@ func TestGetAPIServerClassicELBSpec_ControlPlaneLoadBalancer(t *testing.T) {
 				CrossZoneLoadBalancing: true,
 			},
 			mocks: func(m *mock_ec2iface.MockEC2APIMockRecorder) {},
-			expect: func(t *testing.T, g *WithT, res *infrav1.ClassicELB) {
+			expect: func(t *testing.T, res *infrav1.ClassicELB) {
 				t.Helper()
 				if !res.Attributes.CrossZoneLoadBalancing {
 					t.Error("Expected load balancer to have cross-zone load balancing enabled")
@@ -206,7 +205,7 @@ func TestGetAPIServerClassicELBSpec_ControlPlaneLoadBalancer(t *testing.T) {
 						},
 					}, nil)
 			},
-			expect: func(t *testing.T, g *WithT, res *infrav1.ClassicELB) {
+			expect: func(t *testing.T, res *infrav1.ClassicELB) {
 				t.Helper()
 				if len(res.SubnetIDs) != 2 {
 					t.Errorf("Expected load balancer to be configured for 2 subnets, got %v", len(res.SubnetIDs))
@@ -222,40 +221,17 @@ func TestGetAPIServerClassicELBSpec_ControlPlaneLoadBalancer(t *testing.T) {
 				AdditionalSecurityGroups: []string{"sg-00001", "sg-00002"},
 			},
 			mocks: func(m *mock_ec2iface.MockEC2APIMockRecorder) {},
-			expect: func(t *testing.T, g *WithT, res *infrav1.ClassicELB) {
+			expect: func(t *testing.T, res *infrav1.ClassicELB) {
 				t.Helper()
 				if len(res.SecurityGroupIDs) != 3 {
 					t.Errorf("Expected load balancer to be configured for 3 security groups, got %v", len(res.SecurityGroupIDs))
 				}
 			},
 		},
-		{
-			name: "Should create load balancer spec if elb health check protocol specified in config",
-			lb: &infrav1.AWSLoadBalancerSpec{
-				HealthCheckProtocol: &infrav1.ClassicELBProtocolTCP,
-			},
-			mocks: func(m *mock_ec2iface.MockEC2APIMockRecorder) {},
-			expect: func(t *testing.T, g *WithT, res *infrav1.ClassicELB) {
-				t.Helper()
-				expectedTarget := fmt.Sprintf("%v:%d", infrav1.ClassicELBProtocolTCP, 6443)
-				g.Expect(expectedTarget, res.HealthCheck.Target)
-			},
-		},
-		{
-			name:  "Should create load balancer spec with default elb health check protocol",
-			lb:    &infrav1.AWSLoadBalancerSpec{},
-			mocks: func(m *mock_ec2iface.MockEC2APIMockRecorder) {},
-			expect: func(t *testing.T, g *WithT, res *infrav1.ClassicELB) {
-				t.Helper()
-				expectedTarget := fmt.Sprintf("%v:%d", infrav1.ClassicELBProtocolTCP, 6443)
-				g.Expect(expectedTarget, res.HealthCheck.Target)
-			},
-		},
 	}
 
 	for _, tc := range tests {
 		t.Run(tc.name, func(t *testing.T) {
-			g := NewWithT(t)
 			mockCtrl := gomock.NewController(t)
 			defer mockCtrl.Finish()
 			ec2Mock := mock_ec2iface.NewMockEC2API(mockCtrl)
@@ -294,7 +270,7 @@ func TestGetAPIServerClassicELBSpec_ControlPlaneLoadBalancer(t *testing.T) {
 				t.Fatal(err)
 			}
 
-			tc.expect(t, g, spec)
+			tc.expect(t, spec)
 		})
 	}
 }
diff --git a/pkg/cloud/services/network/secondarycidr_test.go b/pkg/cloud/services/network/secondarycidr_test.go
new file mode 100644
index 000000000..f839061f0
--- /dev/null
+++ b/pkg/cloud/services/network/secondarycidr_test.go
@@ -0,0 +1,249 @@
+/*
+Copyright 2022 The Kubernetes Authors.
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+*/
+
+package network
+
+import (
+	"testing"
+
+	"github.com/aws/aws-sdk-go/aws"
+	"github.com/aws/aws-sdk-go/service/ec2"
+	"github.com/golang/mock/gomock"
+	. "github.com/onsi/gomega"
+	"k8s.io/apimachinery/pkg/runtime"
+	"k8s.io/utils/pointer"
+	"sigs.k8s.io/controller-runtime/pkg/client"
+	"sigs.k8s.io/controller-runtime/pkg/client/fake"
+
+	infrav1 "sigs.k8s.io/cluster-api-provider-aws/api/v1beta1"
+	ekscontrolplanev1 "sigs.k8s.io/cluster-api-provider-aws/controlplane/eks/api/v1beta1"
+	"sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/awserrors"
+	"sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/scope"
+	"sigs.k8s.io/cluster-api-provider-aws/pkg/cloud/services/ec2/mock_ec2iface"
+	"sigs.k8s.io/cluster-api/api/v1beta1"
+)
+
+func setupNewManagedControlPlaneScope(cl client.Client) (*scope.ManagedControlPlaneScope, error) {
+	return scope.NewManagedControlPlaneScope(scope.ManagedControlPlaneScopeParams{
+		Client:  cl,
+		Cluster: &v1beta1.Cluster{},
+		ControlPlane: &ekscontrolplanev1.AWSManagedControlPlane{
+			Spec: ekscontrolplanev1.AWSManagedControlPlaneSpec{
+				SecondaryCidrBlock: pointer.StringPtr("secondary-cidr"),
+				NetworkSpec: infrav1.NetworkSpec{
+					VPC: infrav1.VPCSpec{ID: "vpc-id"},
+				},
+			},
+		},
+	})
+}
+
+func setupScheme() (*runtime.Scheme, error) {
+	scheme := runtime.NewScheme()
+	if err := ekscontrolplanev1.AddToScheme(scheme); err != nil {
+		return nil, err
+	}
+	return scheme, nil
+}
+
+func TestService_associateSecondaryCidr(t *testing.T) {
+	mockCtrl := gomock.NewController(t)
+	defer mockCtrl.Finish()
+
+	tests := []struct {
+		name              string
+		haveSecondaryCIDR bool
+		expect            func(m *mock_ec2iface.MockEC2APIMockRecorder)
+		wantErr           bool
+	}{
+		{
+			name: "Should not associate secondary CIDR if no secondary cidr block info present in control plane",
+		},
+		{
+			name:              "Should return error if unable to describe VPC",
+			haveSecondaryCIDR: true,
+			expect: func(m *mock_ec2iface.MockEC2APIMockRecorder) {
+				m.DescribeVpcs(gomock.AssignableToTypeOf(&ec2.DescribeVpcsInput{})).Return(nil, awserrors.NewFailedDependency("dependency-failure"))
+			},
+			wantErr: true,
+		},
+		{
+			name:              "Should not associate secondary cidr block if already exist in VPC",
+			haveSecondaryCIDR: true,
+			expect: func(m *mock_ec2iface.MockEC2APIMockRecorder) {
+				m.DescribeVpcs(gomock.AssignableToTypeOf(&ec2.DescribeVpcsInput{})).Return(&ec2.DescribeVpcsOutput{
+					Vpcs: []*ec2.Vpc{
+						{
+							CidrBlockAssociationSet: []*ec2.VpcCidrBlockAssociation{
+								{CidrBlock: aws.String("secondary-cidr")},
+							},
+						},
+					}}, nil)
+			},
+		},
+		{
+			name:              "Should return error if no VPC found",
+			haveSecondaryCIDR: true,
+			expect: func(m *mock_ec2iface.MockEC2APIMockRecorder) {
+				m.DescribeVpcs(gomock.AssignableToTypeOf(&ec2.DescribeVpcsInput{})).Return(nil, nil)
+			},
+			wantErr: true,
+		},
+		{
+			name:              "Should return error if failed during associating secondary cidr block",
+			haveSecondaryCIDR: true,
+			expect: func(m *mock_ec2iface.MockEC2APIMockRecorder) {
+				m.DescribeVpcs(gomock.AssignableToTypeOf(&ec2.DescribeVpcsInput{})).Return(&ec2.DescribeVpcsOutput{
+					Vpcs: []*ec2.Vpc{
+						{
+							CidrBlockAssociationSet: []*ec2.VpcCidrBlockAssociation{
+								{CidrBlock: aws.String("secondary-cidr-new")},
+							},
+						},
+					}}, nil)
+				m.AssociateVpcCidrBlock(gomock.AssignableToTypeOf(&ec2.AssociateVpcCidrBlockInput{})).Return(nil, awserrors.NewFailedDependency("dependency-failure"))
+			},
+			wantErr: true,
+		},
+	}
+	for _, tt := range tests {
+		t.Run(tt.name, func(t *testing.T) {
+			g := NewWithT(t)
+
+			scheme, err := setupScheme()
+			g.Expect(err).NotTo(HaveOccurred())
+			cl := fake.NewClientBuilder().WithScheme(scheme).Build()
+
+			ec2Mock := mock_ec2iface.NewMockEC2API(mockCtrl)
+
+			mcpScope, err := setupNewManagedControlPlaneScope(cl)
+			g.Expect(err).NotTo(HaveOccurred())
+
+			if !tt.haveSecondaryCIDR {
+				mcpScope.ControlPlane.Spec.SecondaryCidrBlock = nil
+			}
+
+			s := NewService(mcpScope)
+			s.EC2Client = ec2Mock
+
+			if tt.expect != nil {
+				tt.expect(ec2Mock.EXPECT())
+			}
+
+			err = s.associateSecondaryCidr()
+			if tt.wantErr {
+				g.Expect(err).To(HaveOccurred())
+				return
+			}
+			g.Expect(err).NotTo(HaveOccurred())
+		})
+	}
+}
+
+func TestService_diassociateSecondaryCidr(t *testing.T) {
+	mockCtrl := gomock.NewController(t)
+	defer mockCtrl.Finish()
+
+	tests := []struct {
+		name              string
+		haveSecondaryCIDR bool
+		expect            func(m *mock_ec2iface.MockEC2APIMockRecorder)
+		wantErr           bool
+	}{
+		{
+			name: "Should not disassociate secondary CIDR if no secondary cidr block info present in control plane",
+		},
+		{
+			name:              "Should return error if unable to describe VPC",
+			haveSecondaryCIDR: true,
+			expect: func(m *mock_ec2iface.MockEC2APIMockRecorder) {
+				m.DescribeVpcs(gomock.AssignableToTypeOf(&ec2.DescribeVpcsInput{})).Return(nil, awserrors.NewFailedDependency("dependency-failure"))
+			},
+			wantErr: true,
+		},
+		{
+			name:              "Should return error if no VPC found",
+			haveSecondaryCIDR: true,
+			expect: func(m *mock_ec2iface.MockEC2APIMockRecorder) {
+				m.DescribeVpcs(gomock.AssignableToTypeOf(&ec2.DescribeVpcsInput{})).Return(nil, nil)
+			},
+			wantErr: true,
+		},
+		{
+			name:              "Should diassociate secondary cidr block if already exist in VPC",
+			haveSecondaryCIDR: true,
+			expect: func(m *mock_ec2iface.MockEC2APIMockRecorder) {
+				m.DescribeVpcs(gomock.AssignableToTypeOf(&ec2.DescribeVpcsInput{})).Return(&ec2.DescribeVpcsOutput{
+					Vpcs: []*ec2.Vpc{
+						{
+							CidrBlockAssociationSet: []*ec2.VpcCidrBlockAssociation{
+								{CidrBlock: aws.String("secondary-cidr")},
+							},
+						},
+					}}, nil)
+				m.DisassociateVpcCidrBlock(gomock.AssignableToTypeOf(&ec2.DisassociateVpcCidrBlockInput{})).Return(nil, nil)
+			},
+		},
+		{
+			name:              "Should return error if failed to diassociate secondary cidr block",
+			haveSecondaryCIDR: true,
+			expect: func(m *mock_ec2iface.MockEC2APIMockRecorder) {
+				m.DescribeVpcs(gomock.AssignableToTypeOf(&ec2.DescribeVpcsInput{})).Return(&ec2.DescribeVpcsOutput{
+					Vpcs: []*ec2.Vpc{
+						{
+							CidrBlockAssociationSet: []*ec2.VpcCidrBlockAssociation{
+								{CidrBlock: aws.String("secondary-cidr")},
+							},
+						},
+					}}, nil)
+				m.DisassociateVpcCidrBlock(gomock.AssignableToTypeOf(&ec2.DisassociateVpcCidrBlockInput{})).Return(nil, awserrors.NewFailedDependency("dependency-failure"))
+			},
+			wantErr: true,
+		},
+	}
+	for _, tt := range tests {
+		t.Run(tt.name, func(t *testing.T) {
+			g := NewWithT(t)
+
+			scheme, err := setupScheme()
+			g.Expect(err).NotTo(HaveOccurred())
+			cl := fake.NewClientBuilder().WithScheme(scheme).Build()
+
+			ec2Mock := mock_ec2iface.NewMockEC2API(mockCtrl)
+
+			mcpScope, err := setupNewManagedControlPlaneScope(cl)
+			g.Expect(err).NotTo(HaveOccurred())
+
+			if !tt.haveSecondaryCIDR {
+				mcpScope.ControlPlane.Spec.SecondaryCidrBlock = nil
+			}
+
+			s := NewService(mcpScope)
+			s.EC2Client = ec2Mock
+
+			if tt.expect != nil {
+				tt.expect(ec2Mock.EXPECT())
+			}
+
+			err = s.disassociateSecondaryCidr()
+			if tt.wantErr {
+				g.Expect(err).To(HaveOccurred())
+				return
+			}
+			g.Expect(err).NotTo(HaveOccurred())
+		})
+	}
+}
diff --git a/test/e2e/data/e2e_eks_conf.yaml b/test/e2e/data/e2e_eks_conf.yaml
index 64bdc65eb..daaa9448a 100644
--- a/test/e2e/data/e2e_eks_conf.yaml
+++ b/test/e2e/data/e2e_eks_conf.yaml
@@ -2,6 +2,8 @@
 # E2E test scenario using local dev images and manifests built from the source tree for following providers:
 # - cluster-api
 # - infrastructure aws
+# - boostrap aws-eks
+# - control-plane aws-eks
 
 # To run tests, run the following from the root of this repository.
 # `AWS_REGION=eu-west-1 make e2e GINKGO_ARGS=-stream E2E_ARGS=-skip-cloudformation-deletion`
diff --git a/test/e2e/data/infrastructure-aws/kustomize_sources/limit-az/kustomization.yaml b/test/e2e/data/infrastructure-aws/kustomize_sources/limit-az/kustomization.yaml
index fc5f76bee..e5399ad3a 100644
--- a/test/e2e/data/infrastructure-aws/kustomize_sources/limit-az/kustomization.yaml
+++ b/test/e2e/data/infrastructure-aws/kustomize_sources/limit-az/kustomization.yaml
@@ -2,4 +2,3 @@ resources:
   - ../default
 patchesStrategicMerge:
   - patches/limit-az.yaml
-  - patches/elb-health-check-protocol.yaml
diff --git a/test/e2e/data/infrastructure-aws/kustomize_sources/limit-az/patches/elb-health-check-protocol.yaml b/test/e2e/data/infrastructure-aws/kustomize_sources/limit-az/patches/elb-health-check-protocol.yaml
deleted file mode 100644
index 42f5c9853..000000000
--- a/test/e2e/data/infrastructure-aws/kustomize_sources/limit-az/patches/elb-health-check-protocol.yaml
+++ /dev/null
@@ -1,8 +0,0 @@
----
-apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
-kind: AWSCluster
-metadata:
-  name: "${CLUSTER_NAME}"
-spec:
-  controlPlaneLoadBalancer:
-    healthCheckProtocol: "TCP"
diff --git a/test/e2e/shared/aws.go b/test/e2e/shared/aws.go
index e8538dc07..bd74fd5f9 100644
--- a/test/e2e/shared/aws.go
+++ b/test/e2e/shared/aws.go
@@ -692,744 +692,3 @@ func ListVPC(e2eCtx *E2EContext) int {
 
 	return len(out.Vpcs)
 }
-
-func GetVPC(e2eCtx *E2EContext, vpcID string) (*ec2.Vpc, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("vpc-id"),
-		Values: aws.StringSlice([]string{vpcID}),
-	}
-
-	input := &ec2.DescribeVpcsInput{
-		Filters: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeVpcs(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.Vpcs[0], nil
-}
-
-func CreateVPC(e2eCtx *E2EContext, vpcName string, cidrBlock string) (*ec2.Vpc, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.CreateVpcInput{
-		CidrBlock: aws.String(cidrBlock),
-		TagSpecifications: []*ec2.TagSpecification{
-			{
-				ResourceType: aws.String("vpc"),
-				Tags: []*ec2.Tag{
-					{
-						Key:   aws.String("Name"),
-						Value: aws.String(vpcName),
-					},
-				},
-			},
-		},
-	}
-	result, err := ec2Svc.CreateVpc(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.Vpc, nil
-}
-
-func DeleteVPC(e2eCtx *E2EContext, vpcID string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.DeleteVpcInput{
-		VpcId: aws.String(vpcID),
-	}
-	if _, err := ec2Svc.DeleteVpc(input); err != nil {
-		return false, err
-	}
-	return true, nil
-}
-
-func ListVpcSubnets(e2eCtx *E2EContext, vpcID string) ([]*ec2.Subnet, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("vpc-id"),
-		Values: aws.StringSlice([]string{vpcID}),
-	}
-
-	input := &ec2.DescribeSubnetsInput{
-		Filters: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeSubnets(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.Subnets, nil
-}
-
-func GetSubnet(e2eCtx *E2EContext, subnetID string) (*ec2.Subnet, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("subnet-id"),
-		Values: aws.StringSlice([]string{subnetID}),
-	}
-
-	input := &ec2.DescribeSubnetsInput{
-		Filters: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeSubnets(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.Subnets[0], nil
-}
-
-func CreateSubnet(e2eCtx *E2EContext, clusterName string, cidrBlock string, az string, vpcID string, st string) (*ec2.Subnet, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.CreateSubnetInput{
-		CidrBlock: aws.String(cidrBlock),
-		VpcId:     aws.String(vpcID),
-		TagSpecifications: []*ec2.TagSpecification{
-			{
-				ResourceType: aws.String("subnet"),
-				Tags: []*ec2.Tag{
-					{
-						Key:   aws.String("Name"),
-						Value: aws.String(clusterName + "-subnet-" + st),
-					},
-					{
-						Key:   aws.String("kubernetes.io/cluster/" + clusterName),
-						Value: aws.String("shared"),
-					},
-				},
-			},
-		},
-	}
-
-	// Tag subnet based on type(st)
-	switch st {
-	case "private":
-		input.TagSpecifications[0].Tags = append(input.TagSpecifications[0].Tags, &ec2.Tag{
-			Key:   aws.String("kubernetes.io/role/internal-elb"),
-			Value: aws.String("1"),
-		})
-	case "public":
-		input.TagSpecifications[0].Tags = append(input.TagSpecifications[0].Tags, &ec2.Tag{
-			Key:   aws.String("kubernetes.io/role/elb"),
-			Value: aws.String("1"),
-		})
-	}
-
-	if az != "" {
-		input.AvailabilityZone = aws.String(az)
-	}
-
-	result, err := ec2Svc.CreateSubnet(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.Subnet, nil
-}
-
-func DeleteSubnet(e2eCtx *E2EContext, subnetID string) bool {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.DeleteSubnetInput{
-		SubnetId: aws.String(subnetID),
-	}
-
-	if _, err := ec2Svc.DeleteSubnet(input); err != nil {
-		return false
-	}
-	return true
-}
-
-func AllocateAddress(e2eCtx *E2EContext, eipName string) (*ec2.AllocateAddressOutput, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.AllocateAddressInput{
-		Domain: aws.String("vpc"),
-		TagSpecifications: []*ec2.TagSpecification{
-			{
-				ResourceType: aws.String("elastic-ip"),
-				Tags: []*ec2.Tag{
-					{
-						Key:   aws.String("Name"),
-						Value: aws.String(eipName),
-					},
-				},
-			},
-		},
-	}
-
-	result, err := ec2Svc.AllocateAddress(input)
-	if err != nil {
-		return nil, err
-	}
-	return result, nil
-}
-
-func ReleaseAddress(e2eCtx *E2EContext, allocID string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.ReleaseAddressInput{
-		AllocationId: aws.String(allocID),
-	}
-
-	if _, err := ec2Svc.ReleaseAddress(input); err != nil {
-		return false, err
-	}
-	return true, nil
-}
-
-func CreateNatGateway(e2eCtx *E2EContext, gatewayName string, connectType string, allocID string, subnetID string) (*ec2.NatGateway, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.CreateNatGatewayInput{
-		SubnetId: aws.String(subnetID),
-		TagSpecifications: []*ec2.TagSpecification{
-			{
-				ResourceType: aws.String("natgateway"),
-				Tags: []*ec2.Tag{
-					{
-						Key:   aws.String("Name"),
-						Value: aws.String(gatewayName),
-					},
-				},
-			},
-		},
-	}
-
-	if connectType != "" {
-		input.ConnectivityType = aws.String(connectType)
-	}
-
-	if allocID != "" {
-		input.AllocationId = aws.String(allocID)
-	}
-
-	result, err := ec2Svc.CreateNatGateway(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.NatGateway, nil
-}
-
-func GetNatGateway(e2eCtx *E2EContext, gatewayID string) (*ec2.NatGateway, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("nat-gateway-id"),
-		Values: aws.StringSlice([]string{gatewayID}),
-	}
-
-	input := &ec2.DescribeNatGatewaysInput{
-		Filter: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeNatGateways(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.NatGateways[0], nil
-}
-
-func DeleteNatGateway(e2eCtx *E2EContext, gatewayID string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.DeleteNatGatewayInput{
-		NatGatewayId: aws.String(gatewayID),
-	}
-
-	if _, err := ec2Svc.DeleteNatGateway(input); err != nil {
-		return false, err
-	}
-	return true, nil
-}
-
-func CreateInternetGateway(e2eCtx *E2EContext, gatewayName string) (*ec2.InternetGateway, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.CreateInternetGatewayInput{
-		TagSpecifications: []*ec2.TagSpecification{
-			{
-				ResourceType: aws.String("internet-gateway"),
-				Tags: []*ec2.Tag{
-					{
-						Key:   aws.String("Name"),
-						Value: aws.String(gatewayName),
-					},
-				},
-			},
-		},
-	}
-
-	result, err := ec2Svc.CreateInternetGateway(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.InternetGateway, nil
-}
-
-func GetInternetGateway(e2eCtx *E2EContext, gatewayID string) (*ec2.InternetGateway, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("internet-gateway-id"),
-		Values: aws.StringSlice([]string{gatewayID}),
-	}
-
-	input := &ec2.DescribeInternetGatewaysInput{
-		Filters: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeInternetGateways(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.InternetGateways[0], nil
-}
-
-func DeleteInternetGateway(e2eCtx *E2EContext, gatewayID string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.DeleteInternetGatewayInput{
-		InternetGatewayId: aws.String(gatewayID),
-	}
-
-	if _, err := ec2Svc.DeleteInternetGateway(input); err != nil {
-		return false, err
-	}
-	return true, nil
-}
-
-func AttachInternetGateway(e2eCtx *E2EContext, gatewayID string, vpcID string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.AttachInternetGatewayInput{
-		InternetGatewayId: aws.String(gatewayID),
-		VpcId:             aws.String(vpcID),
-	}
-
-	if _, err := ec2Svc.AttachInternetGateway(input); err != nil {
-		return false, err
-	}
-	return true, nil
-}
-
-func CreatePeering(e2eCtx *E2EContext, peerName string, vpcID string, peerVpcID string) (*ec2.VpcPeeringConnection, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.CreateVpcPeeringConnectionInput{
-		VpcId:     aws.String(vpcID),
-		PeerVpcId: aws.String(peerVpcID),
-		TagSpecifications: []*ec2.TagSpecification{
-			{
-				ResourceType: aws.String("vpc-peering-connection"),
-				Tags: []*ec2.Tag{
-					{
-						Key:   aws.String("Name"),
-						Value: aws.String(peerName),
-					},
-				},
-			},
-		},
-	}
-
-	result, err := ec2Svc.CreateVpcPeeringConnection(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.VpcPeeringConnection, nil
-}
-
-func DeletePeering(e2eCtx *E2EContext, peeringID string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.DeleteVpcPeeringConnectionInput{
-		VpcPeeringConnectionId: aws.String(peeringID),
-	}
-
-	if _, err := ec2Svc.DeleteVpcPeeringConnection(input); err != nil {
-		return false, err
-	}
-	return true, nil
-}
-
-func AcceptPeering(e2eCtx *E2EContext, peeringID string) (*ec2.VpcPeeringConnection, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.AcceptVpcPeeringConnectionInput{
-		VpcPeeringConnectionId: aws.String(peeringID),
-	}
-
-	result, err := ec2Svc.AcceptVpcPeeringConnection(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.VpcPeeringConnection, nil
-}
-
-func CreateRouteTable(e2eCtx *E2EContext, rtName string, vpcID string) (*ec2.RouteTable, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.CreateRouteTableInput{
-		VpcId: aws.String(vpcID),
-		TagSpecifications: []*ec2.TagSpecification{
-			{
-				ResourceType: aws.String("route-table"),
-				Tags: []*ec2.Tag{
-					{
-						Key:   aws.String("Name"),
-						Value: aws.String(rtName),
-					},
-				},
-			},
-		},
-	}
-
-	result, err := ec2Svc.CreateRouteTable(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.RouteTable, nil
-}
-
-func ListVpcRouteTables(e2eCtx *E2EContext, vpcID string) ([]*ec2.RouteTable, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("vpc-id"),
-		Values: aws.StringSlice([]string{vpcID}),
-	}
-
-	input := &ec2.DescribeRouteTablesInput{
-		Filters: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeRouteTables(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.RouteTables, nil
-}
-
-func ListSubnetRouteTables(e2eCtx *E2EContext, subnetID string) ([]*ec2.RouteTable, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("association.subnet-id"),
-		Values: aws.StringSlice([]string{subnetID}),
-	}
-
-	input := &ec2.DescribeRouteTablesInput{
-		Filters: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeRouteTables(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.RouteTables, nil
-}
-
-func GetRouteTable(e2eCtx *E2EContext, rtID string) (*ec2.RouteTable, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("route-table-id"),
-		Values: aws.StringSlice([]string{rtID}),
-	}
-
-	input := &ec2.DescribeRouteTablesInput{
-		Filters: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeRouteTables(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.RouteTables[0], nil
-}
-
-func DeleteRouteTable(e2eCtx *E2EContext, rtID string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.DeleteRouteTableInput{
-		RouteTableId: aws.String(rtID),
-	}
-
-	if _, err := ec2Svc.DeleteRouteTable(input); err != nil {
-		return false, err
-	}
-	return true, nil
-}
-
-func CreateRoute(e2eCtx *E2EContext, rtID string, destinationCidr string, natID *string, igwID *string, pcxID *string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.CreateRouteInput{
-		RouteTableId:         &rtID,
-		DestinationCidrBlock: aws.String(destinationCidr),
-	}
-
-	if natID != nil {
-		input.NatGatewayId = natID
-	}
-
-	if igwID != nil {
-		input.GatewayId = igwID
-	}
-
-	if pcxID != nil {
-		input.VpcPeeringConnectionId = pcxID
-	}
-
-	result, err := ec2Svc.CreateRoute(input)
-	if err != nil {
-		return false, err
-	}
-	created := *result.Return
-	return created, nil
-}
-
-func DeleteRoute(e2eCtx *E2EContext, rtID string, destinationCidr string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.DeleteRouteInput{
-		RouteTableId:         aws.String(rtID),
-		DestinationCidrBlock: aws.String(destinationCidr),
-	}
-
-	if _, err := ec2Svc.DeleteRoute(input); err != nil {
-		return false, err
-	}
-	return true, nil
-}
-
-func CreateSecurityGroup(e2eCtx *E2EContext, sgName string, sgDescription string, vpcID string) (*ec2.CreateSecurityGroupOutput, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.CreateSecurityGroupInput{
-		VpcId:       aws.String(vpcID),
-		GroupName:   aws.String(sgName),
-		Description: aws.String(sgDescription),
-		TagSpecifications: []*ec2.TagSpecification{
-			{
-				ResourceType: aws.String("security-group"),
-				Tags: []*ec2.Tag{
-					{
-						Key:   aws.String("Name"),
-						Value: aws.String(sgName),
-					},
-				},
-			},
-		},
-	}
-
-	result, err := ec2Svc.CreateSecurityGroup(input)
-	if err != nil {
-		return nil, err
-	}
-	return result, nil
-}
-
-func GetSecurityGroup(e2eCtx *E2EContext, sgID string) (*ec2.SecurityGroup, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("group-id"),
-		Values: aws.StringSlice([]string{sgID}),
-	}
-
-	input := &ec2.DescribeSecurityGroupsInput{
-		Filters: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeSecurityGroups(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.SecurityGroups[0], nil
-}
-
-func DeleteSecurityGroup(e2eCtx *E2EContext, sgID string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.DeleteSecurityGroupInput{
-		GroupId: aws.String(sgID),
-	}
-
-	if _, err := ec2Svc.DeleteSecurityGroup(input); err != nil {
-		return false, err
-	}
-	return true, nil
-}
-
-func ListSecurityGroupRules(e2eCtx *E2EContext, sgID string) ([]*ec2.SecurityGroupRule, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("group-id"),
-		Values: aws.StringSlice([]string{sgID}),
-	}
-
-	input := &ec2.DescribeSecurityGroupRulesInput{
-		Filters: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeSecurityGroupRules(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.SecurityGroupRules, nil
-}
-
-func GetSecurityGroupRule(e2eCtx *E2EContext, sgrID string) (*ec2.SecurityGroupRule, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	filter := &ec2.Filter{
-		Name:   aws.String("security-group-rule-id"),
-		Values: aws.StringSlice([]string{sgrID}),
-	}
-
-	input := &ec2.DescribeSecurityGroupRulesInput{
-		Filters: []*ec2.Filter{
-			filter,
-		},
-	}
-
-	result, err := ec2Svc.DescribeSecurityGroupRules(input)
-	if err != nil {
-		return nil, err
-	}
-	return result.SecurityGroupRules[0], nil
-}
-
-func CreateSecurityGroupIngressRule(e2eCtx *E2EContext, sgID string, sgrDescription string, cidr string, protocol string, fromPort int64, toPort int64) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	ipPerm := &ec2.IpPermission{
-		FromPort:   aws.Int64(fromPort),
-		ToPort:     aws.Int64(toPort),
-		IpProtocol: aws.String(protocol),
-		IpRanges: []*ec2.IpRange{
-			{
-				CidrIp:      aws.String(cidr),
-				Description: aws.String(sgrDescription),
-			},
-		},
-	}
-
-	input := &ec2.AuthorizeSecurityGroupIngressInput{
-		GroupId: aws.String(sgID),
-		IpPermissions: []*ec2.IpPermission{
-			ipPerm,
-		},
-	}
-
-	result, err := ec2Svc.AuthorizeSecurityGroupIngress(input)
-	if err != nil {
-		return false, err
-	}
-	return *result.Return, nil
-}
-
-func CreateSecurityGroupEgressRule(e2eCtx *E2EContext, sgID string, sgrDescription string, cidr string, protocol string, fromPort int64, toPort int64) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	ipPerm := &ec2.IpPermission{
-		FromPort:   aws.Int64(fromPort),
-		ToPort:     aws.Int64(toPort),
-		IpProtocol: aws.String(protocol),
-		IpRanges: []*ec2.IpRange{
-			{
-				CidrIp:      aws.String(cidr),
-				Description: aws.String(sgrDescription),
-			},
-		},
-	}
-
-	input := &ec2.AuthorizeSecurityGroupEgressInput{
-		GroupId: aws.String(sgID),
-		IpPermissions: []*ec2.IpPermission{
-			ipPerm,
-		},
-	}
-	result, err := ec2Svc.AuthorizeSecurityGroupEgress(input)
-	if err != nil {
-		return false, err
-	}
-	return *result.Return, nil
-}
-
-func CreateSecurityGroupRule(e2eCtx *E2EContext, sgID string, sgrDescription string, cidr string, protocol string, fromPort int64, toPort int64, rt string) (bool, error) {
-	switch rt {
-	case "ingress":
-		return CreateSecurityGroupIngressRule(e2eCtx, sgID, sgrDescription, cidr, protocol, fromPort, toPort)
-	case "egress":
-		return CreateSecurityGroupEgressRule(e2eCtx, sgID, sgrDescription, cidr, protocol, fromPort, toPort)
-	}
-	return false, nil
-}
-
-func DeleteSecurityGroupIngressRule(e2eCtx *E2EContext, sgrID string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.RevokeSecurityGroupIngressInput{
-		SecurityGroupRuleIds: aws.StringSlice([]string{sgrID}),
-	}
-
-	result, err := ec2Svc.RevokeSecurityGroupIngress(input)
-	if err != nil {
-		return false, err
-	}
-	return *result.Return, nil
-}
-
-func DeleteSecurityGroupEgressRule(e2eCtx *E2EContext, sgrID string) (bool, error) {
-	ec2Svc := ec2.New(e2eCtx.AWSSession)
-
-	input := &ec2.RevokeSecurityGroupEgressInput{
-		SecurityGroupRuleIds: aws.StringSlice([]string{sgrID}),
-	}
-
-	result, err := ec2Svc.RevokeSecurityGroupEgress(input)
-	if err != nil {
-		return false, err
-	}
-	return *result.Return, nil
-}
-
-func DeleteSecurityGroupRule(e2eCtx *E2EContext, sgrID string, rt string) (bool, error) {
-	switch rt {
-	case "ingress":
-		return DeleteSecurityGroupIngressRule(e2eCtx, sgrID)
-	case "egress":
-		return DeleteSecurityGroupEgressRule(e2eCtx, sgrID)
-	}
-	return false, nil
-}
diff --git a/test/e2e/shared/identity.go b/test/e2e/shared/identity.go
index d6d36c9d0..5b749612c 100644
--- a/test/e2e/shared/identity.go
+++ b/test/e2e/shared/identity.go
@@ -35,11 +35,12 @@ const (
 	idName          = "e2e-account"
 )
 
-func SetupStaticCredentials(e2eCtx *E2EContext) {
+func SetupStaticCredentials(ctx context.Context, namespace *corev1.Namespace, e2eCtx *E2EContext) {
+	Expect(ctx).NotTo(BeNil(), "ctx is required for SetupStaticCredentials")
+	Expect(namespace).NotTo(BeNil(), "namespace is required for SetupStaticCredentials")
 	Expect(e2eCtx).NotTo(BeNil(), "e2eCtx is required for SetupStaticCredentials")
 	Expect(e2eCtx.Environment.BootstrapAccessKey).NotTo(BeNil(), "e2eCtx.Environment.BootstrapAccessKey is required for SetupStaticCredentials")
 
-	ctx := context.TODO()
 	secret := &corev1.Secret{
 		ObjectMeta: metav1.ObjectMeta{
 			Name:      credsSecretName,
@@ -59,33 +60,38 @@ func SetupStaticCredentials(e2eCtx *E2EContext) {
 
 	id := &infrav1.AWSClusterStaticIdentity{
 		ObjectMeta: metav1.ObjectMeta{
-			Name: idName,
+			Name:      idName,
+			Namespace: namespace.Name,
 		},
 		Spec: infrav1.AWSClusterStaticIdentitySpec{
 			SecretRef: credsSecretName,
 			AWSClusterIdentitySpec: infrav1.AWSClusterIdentitySpec{
-				AllowedNamespaces: &infrav1.AllowedNamespaces{},
+				AllowedNamespaces: &infrav1.AllowedNamespaces{
+					NamespaceList: []string{namespace.Name},
+				},
 			},
 		},
 	}
 
-	Byf("Creating AWSClusterStaticIdentity %s", id.Name)
+	Byf("Creating AWSClusterStaticIdentity %s in namespace %s", id.Name, namespace.Name)
 	Eventually(func() error {
 		return client.Create(ctx, id)
 	}, e2eCtx.E2EConfig.GetIntervals("", "wait-create-identity")...).Should(Succeed())
 }
 
-func CleanupStaticCredentials(ctx context.Context, e2eCtx *E2EContext) {
+func CleanupStaticCredentials(ctx context.Context, namespace *corev1.Namespace, e2eCtx *E2EContext) {
 	Expect(ctx).NotTo(BeNil(), "ctx is required for SetupStaticCredentials")
+	Expect(namespace).NotTo(BeNil(), "namespace is required for SetupStaticCredentials")
 	Expect(e2eCtx).NotTo(BeNil(), "e2eCtx is required for SetupStaticCredentials")
 
 	id := &infrav1.AWSClusterStaticIdentity{
 		ObjectMeta: metav1.ObjectMeta{
-			Name: idName,
+			Name:      idName,
+			Namespace: namespace.Name,
 		},
 	}
 
-	Byf("Deleting AWSClusterStaticIdentity %s", idName)
+	Byf("Deleting AWSClusterStaticIdentity %s in namespace %s", idName, namespace.Name)
 	client := e2eCtx.Environment.BootstrapClusterProxy.GetClient()
 	Eventually(func() error {
 		return client.Delete(ctx, id)
diff --git a/test/e2e/shared/suite.go b/test/e2e/shared/suite.go
index 2aa92560c..79a60f69d 100644
--- a/test/e2e/shared/suite.go
+++ b/test/e2e/shared/suite.go
@@ -169,11 +169,6 @@ func Node1BeforeSuite(e2eCtx *E2EContext) []byte {
 
 	CreateAWSClusterControllerIdentity(e2eCtx.Environment.BootstrapClusterProxy.GetClient())
 
-	if e2eCtx.IsManaged {
-		By("Setting up AWS static credentials")
-		SetupStaticCredentials(e2eCtx)
-	}
-
 	conf := synchronizedBeforeTestSuiteConfig{
 		ArtifactFolder:           e2eCtx.Settings.ArtifactFolder,
 		ConfigPath:               e2eCtx.Settings.ConfigPath,
@@ -262,12 +257,6 @@ func Node1AfterSuite(e2eCtx *E2EContext) {
 	ctx, cancel := context.WithTimeout(context.TODO(), 15*time.Minute)
 	DumpEKSClusters(ctx, e2eCtx)
 	DumpCloudTrailEvents(e2eCtx)
-
-	if e2eCtx.IsManaged {
-		By("Deleting AWS static credentials")
-		CleanupStaticCredentials(ctx, e2eCtx)
-	}
-
 	defer cancel()
 	By("Tearing down the management cluster")
 	if !e2eCtx.Settings.SkipCleanup {
diff --git a/test/e2e/suites/managed/cluster.go b/test/e2e/suites/managed/cluster.go
index ab395b072..705bfc5c0 100644
--- a/test/e2e/suites/managed/cluster.go
+++ b/test/e2e/suites/managed/cluster.go
@@ -123,3 +123,27 @@ type DeleteClusterSpecInput struct {
 	Namespace             *corev1.Namespace
 	ClusterName           string
 }
+
+// DeleteClusterSpec implements a test for deleting a Cluster.
+func DeleteClusterSpec(ctx context.Context, inputGetter func() DeleteClusterSpecInput) {
+	input := inputGetter()
+	Expect(input.E2EConfig).ToNot(BeNil(), "Invalid argument. input.E2EConfig can't be nil")
+	Expect(input.BootstrapClusterProxy).ToNot(BeNil(), "Invalid argument. input.BootstrapClusterProxy can't be nil")
+	Expect(input.Namespace).NotTo(BeNil(), "Invalid argument. input.Namespace can't be nil")
+	Expect(input.ClusterName).ShouldNot(HaveLen(0), "Invalid argument. input.ClusterName can't be empty")
+
+	shared.Byf("getting cluster with name %s", input.ClusterName)
+	cluster := framework.GetClusterByName(ctx, framework.GetClusterByNameInput{
+		Getter:    input.BootstrapClusterProxy.GetClient(),
+		Namespace: input.Namespace.Name,
+		Name:      input.ClusterName,
+	})
+	Expect(cluster).NotTo(BeNil(), "couldn't find cluster")
+
+	shared.Byf("Deleting cluster %s/%s", input.Namespace, input.ClusterName)
+
+	framework.DeleteCluster(ctx, framework.DeleteClusterInput{
+		Deleter: input.BootstrapClusterProxy.GetClient(),
+		Cluster: cluster,
+	})
+}
diff --git a/test/e2e/suites/managed/eks_test.go b/test/e2e/suites/managed/eks_test.go
index 0004c8bd8..6c6b26c70 100644
--- a/test/e2e/suites/managed/eks_test.go
+++ b/test/e2e/suites/managed/eks_test.go
@@ -56,6 +56,9 @@ var _ = ginkgo.Describe("[managed] [general] EKS cluster tests", func() {
 		namespace = shared.SetupSpecNamespace(ctx, specName, e2eCtx)
 		clusterName = fmt.Sprintf("cluster-%s", util.RandomString(6))
 
+		ginkgo.By("setting up AWS static credentials")
+		shared.SetupStaticCredentials(ctx, namespace, e2eCtx)
+
 		ginkgo.By("default iam role should exist")
 		verifyRoleExistsAndOwned(ekscontrolplanev1.DefaultEKSControlPlaneRole, clusterName, false, e2eCtx.BootstrapUserAWSSession)
 
@@ -145,5 +148,8 @@ var _ = ginkgo.Describe("[managed] [general] EKS cluster tests", func() {
 			Getter:  e2eCtx.Environment.BootstrapClusterProxy.GetClient(),
 			Cluster: cluster,
 		}, e2eCtx.E2EConfig.GetIntervals("", "wait-delete-cluster")...)
+
+		ginkgo.By("Deleting AWS static credentials")
+		shared.CleanupStaticCredentials(ctx, namespace, e2eCtx)
 	})
 })
diff --git a/test/e2e/suites/managed/upgrade_test.go b/test/e2e/suites/managed/upgrade_test.go
index 3344a6e96..b82dacaa3 100644
--- a/test/e2e/suites/managed/upgrade_test.go
+++ b/test/e2e/suites/managed/upgrade_test.go
@@ -23,21 +23,20 @@ import (
 	"context"
 	"fmt"
 
-	"github.com/onsi/ginkgo"
+	. "github.com/onsi/ginkgo"
 	. "github.com/onsi/gomega"
 	corev1 "k8s.io/api/core/v1"
 
-	ekscontrolplanev1 "sigs.k8s.io/cluster-api-provider-aws/controlplane/eks/api/v1beta1"
 	"sigs.k8s.io/cluster-api-provider-aws/test/e2e/shared"
 	"sigs.k8s.io/cluster-api/test/framework"
 	"sigs.k8s.io/cluster-api/util"
 )
 
 // EKS cluster upgrade tests.
-var _ = ginkgo.Describe("EKS Cluster upgrade test", func() {
+var _ = Describe("EKS Cluster upgrade test", func() {
 	const (
-		initialVersion   = "v1.20.0"
-		upgradeToversion = "v1.21.0"
+		initialVersion   = "v1.17.0"
+		upgradeToversion = "v1.18.0"
 	)
 	var (
 		namespace   *corev1.Namespace
@@ -47,7 +46,7 @@ var _ = ginkgo.Describe("EKS Cluster upgrade test", func() {
 	)
 
 	shared.ConditionalIt(runUpgradeTests, "[managed] [upgrade] should create a cluster and upgrade the kubernetes version", func() {
-		ginkgo.By("should have a valid test configuration")
+		By("should have a valid test configuration")
 		Expect(e2eCtx.Environment.BootstrapClusterProxy).ToNot(BeNil(), "Invalid argument. BootstrapClusterProxy can't be nil")
 		Expect(e2eCtx.E2EConfig).ToNot(BeNil(), "Invalid argument. e2eConfig can't be nil when calling %s spec", specName)
 		Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.KubernetesVersion))
@@ -56,10 +55,7 @@ var _ = ginkgo.Describe("EKS Cluster upgrade test", func() {
 		namespace = shared.SetupSpecNamespace(ctx, specName, e2eCtx)
 		clusterName = fmt.Sprintf("cluster-%s", util.RandomString(6))
 
-		ginkgo.By("default iam role should exist")
-		verifyRoleExistsAndOwned(ekscontrolplanev1.DefaultEKSControlPlaneRole, clusterName, false, e2eCtx.BootstrapUserAWSSession)
-
-		ginkgo.By("should create an EKS control plane")
+		By("should create an EKS control plane")
 		ManagedClusterSpec(ctx, func() ManagedClusterSpecInput {
 			return ManagedClusterSpecInput{
 				E2EConfig:                e2eCtx.E2EConfig,
@@ -108,13 +104,16 @@ var _ = ginkgo.Describe("EKS Cluster upgrade test", func() {
 
 		// TODO (richardcase): add test for the node group upgrade
 
-		framework.DeleteCluster(ctx, framework.DeleteClusterInput{
-			Deleter: e2eCtx.Environment.BootstrapClusterProxy.GetClient(),
-			Cluster: cluster,
+		shared.Byf("should delete cluster %s", clusterName)
+		DeleteClusterSpec(ctx, func() DeleteClusterSpecInput {
+			return DeleteClusterSpecInput{
+				E2EConfig:             e2eCtx.E2EConfig,
+				BootstrapClusterProxy: e2eCtx.Environment.BootstrapClusterProxy,
+				ClusterName:           clusterName,
+				Namespace:             namespace,
+			}
 		})
-		framework.WaitForClusterDeleted(ctx, framework.WaitForClusterDeletedInput{
-			Getter:  e2eCtx.Environment.BootstrapClusterProxy.GetClient(),
-			Cluster: cluster,
-		}, e2eCtx.E2EConfig.GetIntervals("", "wait-delete-cluster")...)
+
 	})
+
 })