-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
Create data yaml based on rules instances #130671
Create data yaml based on rules instances #130671
Conversation
…sPostCreatePackage
…sPostCreatePackage
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.
Looks good but what about adding a test that actually confirms you filter correctly? e.g add different package_policy_id
s and policy_id
to your concrete rules used in the test?
const cspRules = await soClient.find<CspRuleSchema>({ | ||
type: cspRuleAssetSavedObjectType, | ||
search: '', | ||
filter: `csp_rule.attributes.package_policy_id: ${packagePolicy.id} AND csp_rule.attributes.policy_id: ${packagePolicy.policy_id}`, |
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.
maybe use the cspRuleAssetSavedObjectType
for filtering instead csp_rule
as suggeted by @kfirpeled in another PR
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.
tested, lgtm.
see comments before merge
💚 Build SucceededMetrics [docs]
History
To update your PR or re-run it, just comment with: |
it's requires an integration test, I'll add it in another PR |
No description provided.