liquidmetal-dev / liquidmetal-dev/cluster-api-provider-microvm
Change controller tests to use envtest
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 157
- Forks
- 21
- PR merge metrics
- No merged PRs in 30d
Description
**Describe the solution you'd like:**
We need to migrate the controller tests to use envtest in the future so that controller is tested in conjunction with the webhooks etc. This is the common pattern across infra providers.
See CAPA for an example:
- https://github.com/kubernetes-sigs/cluster-api-provider-aws/blob/main/controllers/suite_test.go
- https://github.com/kubernetes-sigs/cluster-api-provider-aws/blob/main/controllers/awscluster_controller_test.go
**Why do you want this feature:**
**Anything else you would like to add:**
[Miscellaneous information that will assist in solving the issue.]
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Locate the controller tests and compare their structure with the referenced CAPA suite_test.go and awscluster_controller_test.go examples. Migrate the tests to envtest so the controller is exercised together with webhooks, and verify the controller test suite passes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, kubernetes
- Domain
- infrastructure, testing
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100