-
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
[Security Solution] data_source
field diff algorithm test plan
#189669
[Security Solution] data_source
field diff algorithm test plan
#189669
Conversation
Pinging @elastic/security-detections-response (Team:Detections and Resp) |
Pinging @elastic/security-solution (Team: SecuritySolution) |
Pinging @elastic/security-detection-rule-management (Team:Detection Rule Management) |
...ution/docs/testing/test_plans/detection_response/prebuilt_rules/upgrade_review_algorithms.md
Show resolved
Hide resolved
...ution/docs/testing/test_plans/detection_response/prebuilt_rules/upgrade_review_algorithms.md
Outdated
Show resolved
Hide resolved
...ution/docs/testing/test_plans/detection_response/prebuilt_rules/upgrade_review_algorithms.md
Outdated
Show resolved
Hide resolved
da35abf
to
0c9ec16
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.
Thanks @dplumlee! I have taken a look and left a couple comments. Will take a more thorough look tomorrow.
...ution/docs/testing/test_plans/detection_response/prebuilt_rules/upgrade_review_algorithms.md
Outdated
Show resolved
Hide resolved
...ution/docs/testing/test_plans/detection_response/prebuilt_rules/upgrade_review_algorithms.md
Outdated
Show resolved
Hide resolved
Examples: | ||
| algorithm | base_version | current_version | target_version | merged_version | | ||
| data_source | {type: "index_patterns", "index_patterns": ["one", "two", "three"]} | {type: "index_patterns", "index_patterns": ["two", "one", "four"]} | {type: "index_patterns", "index_patterns": ["one", "two", "five"]} | {type: "index_patterns", "index_patterns": ["one", "two", "four", "five"]} | | ||
| data_source | {type: "data_view", "data_view_id": "A"} | {type: "index_patterns", "index_patterns": ["one", "one", "two", "three"]} | {type: "index_patterns", "index_patterns": ["one", "two", "five"]} | {type: "index_patterns", "index_patterns": ["one", "two", "three", "five"]} | |
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.
Is this extra "one"
in current_version
intentional?
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.
Yeah, it's similar to the scalar array diff algorithm where we test deduplication, etc., in the arrays. The tests aren't as exhaustive for this algorithm since we're reusing a lot of logic for array comparison and merging but it's still a good idea to test a little bit of it
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.
Finished my review. Added a couple more comments. Please take a look when you can.
...ution/docs/testing/test_plans/detection_response/prebuilt_rules/upgrade_review_algorithms.md
Outdated
Show resolved
Hide resolved
...ution/docs/testing/test_plans/detection_response/prebuilt_rules/upgrade_review_algorithms.md
Show resolved
Hide resolved
...ution/docs/testing/test_plans/detection_response/prebuilt_rules/upgrade_review_algorithms.md
Outdated
Show resolved
Hide resolved
...ution/docs/testing/test_plans/detection_response/prebuilt_rules/upgrade_review_algorithms.md
Outdated
Show resolved
Hide resolved
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.
Thanks for addressing feedback @dplumlee! LGTM now.
After that, all good from my side 👍 ✅ |
…gorithm (#189744) ## Summary Completes #187659 Switches `data_source` fields to use the implemented diff algorithm assigned to them in #188874 Adds integration tests in accordance to #189669 for the `upgrade/_review` API endpoint for the `data_source` field diff algorithm. ### Checklist Delete any items that are not applicable to this PR. - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios - [x] [Flaky Test Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was used on any tests changed ### For maintainers - [ ] This was checked for breaking API changes and was [labeled appropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)
Summary
Related ticket: #187659
Adds test plan for diff algorithm for arrays of scalar values implemented here: #188874
For maintainers