-
Notifications
You must be signed in to change notification settings - Fork 34
Add support for object-templates-raw #158
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
Add support for object-templates-raw #158
Conversation
c1ed5d8 to
49f27aa
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good!
Unless I missed it, could you also add some additional parameters to the tests, like extraDependencies, ignorePending, or evaluationInterval, to make sure those are getting set properly?
| tmpDir := t.TempDir() | ||
| manifestPath := path.Join(tmpDir, "configmap.yaml") | ||
| manifestYAML := ` | ||
| object-templates-raw: | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you have a test to verify when a single manifest file has two object-templates-raw fields? For example:
object-templates-raw: |
something
---
object-templates-raw: |
something2There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I ended up just making the test have two object-templates-raw fields instead of one. Would it still be necessary to test the singular case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think one test with both in it is fine.
2d537df to
a13315c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
/hold in case @dhaiducek wants to take another look.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One more thing I thought of: for due diligence, please also add one configuration to the examples/ directory and also add to the manifests description that we've enabled this:
| # Supported manifests: |
Adds support for manifest files with only object-templates-raw field, which gets put into a ConfigurationPolicy. Signed-off-by: Jeffrey Luo <[email protected]>
|
@dhaiducek let me know if this is good from your perspective to unhold. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks!
The object-templates-raw example doesn't actually have any templates in it, but I think that's fine--if anyone comes looking around in the generator, they're probably already familiar with ConfigurationPolicy anyway.
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: dhaiducek, JeffeyL, mprahl 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 |
|
/unhold |
Adds support for manifest files with only object-templates-raw field, which gets put into a ConfigurationPolicy.
Ref: https://issues.redhat.com/browse/ACM-10565