Skip to content

Support for passing old resource to validator #330

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

jonesbusy
Copy link

Fix #329

This is a breaking change since the validator method changed.

The oldResource is never null. It's only different when performing an UPDATE operation

Useful to validate immutable field on the spec

@jonesbusy jonesbusy force-pushed the feature/support-old-resource branch from 952ac17 to bf93df3 Compare May 15, 2025 11:09
@jonesbusy
Copy link
Author

Applied spotless

@csviri
Copy link
Contributor

csviri commented May 15, 2025

@jonesbusy there some end to end test failing, this might be actually unrelated to you PR, if you could take a look however, that would be great

@jonesbusy
Copy link
Author

Mhh I need to try to run those end2end tests locally as well

Can you try to run again the job to be sure it's not flaky?

@csviri
Copy link
Contributor

csviri commented May 15, 2025

Mhh I need to try to run those end2end tests locally as well

Can you try to run again the job to be sure it's not flaky?

I'm pretty sure e2e broke some point, not a result of this PR. If you have time pls take a look in a separate PR, otherwise I will try to do eventually.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Validation of immutable fields, passing oldResource from admission request
2 participants