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

chore: check test files are up to date #747

Merged
merged 1 commit into from
Sep 12, 2023

Conversation

eddycharly
Copy link
Member

Related Issue(s)

This PR checks test files are up to date.

@eddycharly eddycharly force-pushed the lint-pols branch 7 times, most recently from 3c8ad80 to 81fe442 Compare September 11, 2023 22:28
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
Copy link
Contributor

@chipzoller chipzoller left a comment

Choose a reason for hiding this comment

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

I need some more explanation on this one if you can provide.

@eddycharly
Copy link
Member Author

@chipzoller i added a CLI command kyverno fix test that automatically updates test files:

  • removes usage of deprecated fields
  • compresses results
  • ensures test has a name

This job makes sure that running the command does not change test files in the repo (they are up to date).

@chipzoller
Copy link
Contributor

Ok, so is this expected to produce a failure if a diff is found?

@eddycharly
Copy link
Member Author

Yep, in case of a failure you have to run kyverno fix test . --save --compress and push the changes.

@eddycharly
Copy link
Member Author

I'm thinking about adding a Makefile to make this easier 🤷

@chipzoller chipzoller self-requested a review September 12, 2023 17:44
@eddycharly eddycharly merged commit dc4ecaf into kyverno:main Sep 12, 2023
112 checks passed
@eddycharly eddycharly deleted the lint-pols branch September 12, 2023 21:33
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.

2 participants