Skip to content

Commit

Permalink
E2E Runner using kubetest2-kops
Browse files Browse the repository at this point in the history
  • Loading branch information
nckturner committed Feb 4, 2022
1 parent 3a49c66 commit 930ccbc
Show file tree
Hide file tree
Showing 6 changed files with 1,102 additions and 51 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ _output/
docs/book/_book/
site/
.vscode/
hack/e2e/cloud-provider-test-artifacts
e2e.test
20 changes: 13 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@

.EXPORT_ALL_VARIABLES:

SHELL := /bin/bash
SOURCES := $(shell find . -name '*.go')
GOOS ?= $(shell go env GOOS)
GOARCH ?= $(shell go env GOARCH)
Expand Down Expand Up @@ -66,6 +67,11 @@ docker-build:
--platform linux/amd64,linux/arm64 \
--tag $(IMAGE) .

e2e.test:
pushd tests/e2e > /dev/null && \
go test -c && popd
mv tests/e2e/e2e.test e2e.test

.PHONY: check
check: verify-fmt verify-lint vet

Expand Down Expand Up @@ -107,15 +113,15 @@ kops-example:
./hack/kops-example.sh

.PHONY: test-e2e
test-e2e:
test-e2e: e2e.test
AWS_REGION=us-west-2 \
TEST_PATH=./tests/e2e/... \
GINKGO_FOCUS="\[cloud-provider-aws-e2e\]" \
./hack/e2e/run.sh

.PHONY: test-e2e-install
test-e2e-install:
go install sigs.k8s.io/kubetest2
#go install k8s.io/kops/tests/e2e/kubetest2-tester-kops && \
#go install k8s.io/kops/tests/e2e/kubetest2-kops

# Use `make install-e2e-tools KOPS_ROOT=<local-kops-installation>`
# to skip the kops download, test local changes to the kubetest2-kops
# deployer, etc.
.PHONY: install-e2e-tools
install-e2e-tools:
./hack/install-e2e-tools.sh
7 changes: 4 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ require (
gopkg.in/gcfg.v1 v1.2.0
k8s.io/api v0.23.0
k8s.io/apimachinery v0.23.0
k8s.io/client-go v0.23.0
k8s.io/client-go v9.0.0+incompatible
k8s.io/cloud-provider v0.23.0
k8s.io/code-generator v0.23.0
k8s.io/component-base v0.23.0
Expand Down Expand Up @@ -44,11 +44,11 @@ require (
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/protobuf v1.5.2 // indirect
github.com/google/gofuzz v1.1.0 // indirect
github.com/google/uuid v1.1.2 // indirect
github.com/google/uuid v1.1.4 // indirect
github.com/googleapis/gnostic v0.5.5 // indirect
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 // indirect
github.com/grpc-ecosystem/grpc-gateway v1.16.0 // indirect
github.com/imdario/mergo v0.3.8 // indirect
github.com/imdario/mergo v0.3.11 // indirect
github.com/inconshreveable/mousetrap v1.0.0 // indirect
github.com/jmespath/go-jmespath v0.4.0 // indirect
github.com/josharian/intern v1.0.0 // indirect
Expand Down Expand Up @@ -112,5 +112,6 @@ require (
k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65 // indirect
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.25 // indirect
sigs.k8s.io/json v0.0.0-20211020170558-c049b76a60c6 // indirect
sigs.k8s.io/kubetest2 v0.0.0-20220127004650-cc0c36d0693e // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.1.2 // indirect
)
Loading

0 comments on commit 930ccbc

Please sign in to comment.