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

feat: add kubebuilders validations for name length to be <= 63 #218

Merged
merged 70 commits into from
Jan 4, 2025

Conversation

jamyct
Copy link
Contributor

@jamyct jamyct commented Nov 15, 2024

What type of PR is this?

What this PR does / why we need it:

Which issue(s) this PR fixes:

Fixes #

Requirements:

How has this code been tested

Special notes for your reviewer

@jamyct jamyct changed the title add kubebuilders validations for name length to be <= 63 feat: add kubebuilders validations for name length to be <= 63 Nov 15, 2024
Copy link

codecov bot commented Nov 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 79.90%. Comparing base (78457e5) to head (8078722).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #218      +/-   ##
==========================================
+ Coverage   79.79%   79.90%   +0.10%     
==========================================
  Files          27       27              
  Lines        3846     3846              
==========================================
+ Hits         3069     3073       +4     
+ Misses        622      618       -4     
  Partials      155      155              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@jamyct jamyct added the enhancement New feature or request label Nov 20, 2024
@jamyct jamyct force-pushed the add-resource-validation branch from a87267d to c730655 Compare November 20, 2024 02:13
config/rbac/role.yaml Outdated Show resolved Hide resolved
test/apis/v1alpha1/api_validation_integration_test.go Outdated Show resolved Hide resolved
test/apis/v1alpha1/api_validation_integration_test.go Outdated Show resolved Hide resolved
test/apis/v1alpha1/api_validation_integration_test.go Outdated Show resolved Hide resolved
Copy link
Contributor

@zhiying-lin zhiying-lin left a comment

Choose a reason for hiding this comment

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

Please apply the comments to all the APIs tests.

Makefile Outdated Show resolved Hide resolved
test/apis/v1alpha1/api_validation_integration_test.go Outdated Show resolved Hide resolved
test/apis/v1alpha1/suite_test.go Outdated Show resolved Hide resolved
test/apis/v1alpha1/suite_test.go Outdated Show resolved Hide resolved
test/apis/v1alpha1/suite_test.go Outdated Show resolved Hide resolved
test/apis/v1alpha1/api_validation_integration_test.go Outdated Show resolved Hide resolved
test/apis/v1alpha1/api_validation_integration_test.go Outdated Show resolved Hide resolved
test/apis/v1alpha1/api_validation_integration_test.go Outdated Show resolved Hide resolved
@jamyct jamyct requested a review from ryanzhang-oss January 3, 2025 21:52
@jamyct jamyct merged commit 1c36ce3 into Azure:main Jan 4, 2025
10 checks passed
@jamyct
Copy link
Contributor Author

jamyct commented Jan 4, 2025

TODO:

  1. Use table driven style to iterate through repeated cases/types to reduce code duplication
  2. Consider removing tests unrelated to name size to simplify test file

@zhiying-lin
Copy link
Contributor

For the TODO list,
1)the tests make sure it not only validates the length, but also checks whether it follows RFC 1035.

Please remove the commit messages when you merge the PR next time.
Otherwise, you will see this long commit messages.
image

@jamyct jamyct deleted the add-resource-validation branch January 6, 2025 08:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants