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

🐛 (go/v4): Align webhook suite test with controller's suite test #4449

Conversation

mateusoliveira43
Copy link
Contributor

@mateusoliveira43 mateusoliveira43 commented Dec 27, 2024

Enable conversion webhooks for webhook suite_test.go envtest by using k8s.io/client-go/kubernetes/scheme instead of creating new scheme (this also already done in controller suite_test.go)

  • Updated the webhook suite test to follow the structure and conventions of the controller's suite test.
  • Switched to using k8s.io/client-go/kubernetes/scheme instead of k8s.io/apimachinery/pkg/runtime.
  • This ensures consistency across test suites and improves maintainability.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Dec 27, 2024
@k8s-ci-robot k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Dec 27, 2024
@k8s-ci-robot
Copy link
Contributor

Hi @mateusoliveira43. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. label Dec 27, 2024
camilamacedo86

This comment was marked as outdated.

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Dec 28, 2024
@mateusoliveira43
Copy link
Contributor Author

@camilamacedo86 will undo change to CRDInstallOptions, the default value is what I am adding

// Scheme is used to determine if conversion webhooks should be enabled
// for a particular CRD / object.
//
// Conversion webhooks are going to be enabled if an object in the scheme
// implements Hub and Spoke conversions.
//
// If nil, scheme.Scheme is used.

Will add more info to PR description

@mateusoliveira43 mateusoliveira43 force-pushed the fix/webhook-test-suite-scheme branch 2 times, most recently from 0c36daf to d540c85 Compare December 30, 2024 17:01
@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jan 1, 2025
@camilamacedo86
Copy link
Member

HI @mateusoliveira43

Can you rebase it with the master and ensure that you have what was changed and why in the description?

@mateusoliveira43 mateusoliveira43 force-pushed the fix/webhook-test-suite-scheme branch from d540c85 to f645d9b Compare January 2, 2025 16:48
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Jan 2, 2025
@mateusoliveira43
Copy link
Contributor Author

@camilamacedo86 updated

@camilamacedo86
Copy link
Member

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jan 21, 2025
@camilamacedo86
Copy link
Member

/overwrite pull-kubebuilder-e2e-k8s-1-32-0

Signed-off-by: Mateus Oliveira <[email protected]>
@mateusoliveira43 mateusoliveira43 force-pushed the fix/webhook-test-suite-scheme branch from f645d9b to c122bee Compare January 21, 2025 12:56
@camilamacedo86 camilamacedo86 changed the title 🐛 fix: webhook testEnv 🐛 (go/v4): Align webhook suite test with controller's suite test Jan 22, 2025
@camilamacedo86
Copy link
Member

/overwrite pull-kubebuilder-e2e-k8s-1-32-0

@camilamacedo86
Copy link
Member

Hi @mateusoliveira43

Thank you a lot for check this one 🥇
Note that I updated the title and description to bring a little more clarity and help us when we generate the release notes.
I hope that you do not mind.

Let's move forward with this one

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jan 22, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: camilamacedo86, mateusoliveira43

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jan 22, 2025
@camilamacedo86
Copy link
Member

/hold cancel

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jan 22, 2025
@camilamacedo86
Copy link
Member

/overwrite pull-kubebuilder-e2e-k8s-1-32-0

@camilamacedo86
Copy link
Member

/override pull-kubebuilder-e2e-k8s-1-32-0

@k8s-ci-robot
Copy link
Contributor

@camilamacedo86: Overrode contexts on behalf of camilamacedo86: pull-kubebuilder-e2e-k8s-1-32-0

In response to this:

/override pull-kubebuilder-e2e-k8s-1-32-0

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot merged commit 24f9711 into kubernetes-sigs:master Jan 22, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants