Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install envtest before running the unit tests #1976

Merged
merged 2 commits into from
Oct 21, 2021
Merged

Conversation

stefanprodan
Copy link
Member

@stefanprodan stefanprodan commented Oct 21, 2021

This PR adds a new command to Makefile for installing the envtest binaries (kube-api-server and etcd) before running the unit tests.

Fix: #1974

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
@stefanprodan stefanprodan added area/docs Documentation related issues and pull requests area/ci CI related issues and pull requests labels Oct 21, 2021
@@ -58,6 +58,10 @@ install:
install-dev:
CGO_ENABLED=0 go build -o /usr/local/bin ./cmd/flux


install-envtest: setup-envtest
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would maybe call this config-envtest, as I currently would kind of expect based on the target name that it does what setup-envtest does.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This matches what's in kustomize-controller Makefile. I think we should normalise our Makefiles everywhere at some point.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should merge the 2 into install-envtest which downloads the envtest binary then installs the api and ectd ones.

@stefanprodan stefanprodan merged commit 5c60e79 into main Oct 21, 2021
@stefanprodan stefanprodan deleted the e2e-run-docs branch October 21, 2021 07:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/ci CI related issues and pull requests area/docs Documentation related issues and pull requests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CONTRIBUTING.md missing information on controller-runtime dependency
2 participants