-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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] JSON diffs test plan #175958
Conversation
Pinging @elastic/security-detections-response (Team:Detections and Resp) |
Pinging @elastic/security-detection-rule-management (Team:Detection Rule Management) |
Pinging @elastic/security-solution (Team: SecuritySolution) |
@nikitaindik Let's please request review from someone who's working on the epic. |
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.
@nikitaindik An updated test plan looks good to me 👍
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
|
||
#### **Scenario: User can see precisely how property values would change after upgrade** | ||
|
||
**Automation**: 1 UI component-level test |
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.
Does UI component-level test
represent a unit test or it's something different?
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 envisioned it to be a react-testing-library test where I would render the flyout passing it the current rule and the updated rule as props. Not sure if this can be considered a "unit test", probably more like "integration test". Would "UI integration test" work better?
@nikitaindik Can you add a Table of Contents at the beggining? The file has become large enough already that is hard to navigate or have an overview in mind of the sections:
|
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
Given a rule preview with rule changes is open | ||
Then each line of <column> that was <change_type> should have <bg_color> background | ||
And marked with <line_badge> badge | ||
And each changed word in <column> should be highlighted with <accent_color> |
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 cannot recall now, but we are only using only WORD diffing for the whole JSON, right? No need to test other uses cases, like character diffing.
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.
No, at this stage it's by word only.
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.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.
Some comments and nits, but overall LGTM 👍 ✅
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.
Scenarios look fantastic! Thank you @nikitaindik.
Left a bunch of nits.
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Outdated
Show resolved
Hide resolved
...lution/docs/testing/test_plans/detection_response/prebuilt_rules/installation_and_upgrade.md
Show resolved
Hide resolved
e356ddd
to
63a30ac
Compare
**Resolves: elastic#166162 This PR introduces a test plan for the JSON diff preview. This preview is displayed in the upgrade prebuilt rule flyout. <img width="1209" alt="Schermafbeelding 2024-01-31 om 10 38 51" src="https://github.com/elastic/kibana/assets/15949146/9f4ffcca-31fe-464e-9315-c90ec38696d6">
**Resolves: elastic#166162 This PR introduces a test plan for the JSON diff preview. This preview is displayed in the upgrade prebuilt rule flyout. <img width="1209" alt="Schermafbeelding 2024-01-31 om 10 38 51" src="https://github.com/elastic/kibana/assets/15949146/9f4ffcca-31fe-464e-9315-c90ec38696d6">
**Resolves: #166163 Flaky test runner runs: [1](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5189), [2](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5190), [3](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5191), [4](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5192) ## Summary This PR adds tests in accordance with the [test plan](#175958) that was merged earlier.
**Resolves: elastic#166163 Flaky test runner runs: [1](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5189), [2](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5190), [3](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5191), [4](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5192) ## Summary This PR adds tests in accordance with the [test plan](elastic#175958) that was merged earlier. (cherry picked from commit cd374d2)
# Backport This will backport the following commits from `main` to `8.13`: - [[Security Solution] JSON diffs test coverage (#176770)](#176770) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Nikita Indik","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-02-19T15:12:51Z","message":"[Security Solution] JSON diffs test coverage (#176770)\n\n**Resolves: https://github.com/elastic/kibana/issues/166163**\r\n\r\nFlaky test runner runs:\r\n[1](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5189),\r\n[2](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5190),\r\n[3](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5191),\r\n[4](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5192)\r\n\r\n## Summary\r\nThis PR adds tests in accordance with the [test\r\nplan](#175958) that was merged\r\nearlier.","sha":"cd374d23368de182a96df0948192a9bca7bdc4aa","branchLabelMapping":{"^v8.14.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","test-coverage","Team:Detections and Resp","Team: SecuritySolution","Team:Detection Rule Management","Feature:Prebuilt Detection Rules","v8.13.0","v8.14.0"],"title":"[Security Solution] JSON diffs test coverage","number":176770,"url":"https://github.com/elastic/kibana/pull/176770","mergeCommit":{"message":"[Security Solution] JSON diffs test coverage (#176770)\n\n**Resolves: https://github.com/elastic/kibana/issues/166163**\r\n\r\nFlaky test runner runs:\r\n[1](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5189),\r\n[2](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5190),\r\n[3](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5191),\r\n[4](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5192)\r\n\r\n## Summary\r\nThis PR adds tests in accordance with the [test\r\nplan](#175958) that was merged\r\nearlier.","sha":"cd374d23368de182a96df0948192a9bca7bdc4aa"}},"sourceBranch":"main","suggestedTargetBranches":["8.13"],"targetPullRequestStates":[{"branch":"8.13","label":"v8.13.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.14.0","branchLabelMappingKey":"^v8.14.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/176770","number":176770,"mergeCommit":{"message":"[Security Solution] JSON diffs test coverage (#176770)\n\n**Resolves: https://github.com/elastic/kibana/issues/166163**\r\n\r\nFlaky test runner runs:\r\n[1](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5189),\r\n[2](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5190),\r\n[3](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5191),\r\n[4](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5192)\r\n\r\n## Summary\r\nThis PR adds tests in accordance with the [test\r\nplan](#175958) that was merged\r\nearlier.","sha":"cd374d23368de182a96df0948192a9bca7bdc4aa"}}]}] BACKPORT--> Co-authored-by: Nikita Indik <[email protected]>
**Resolves: elastic#166162 This PR introduces a test plan for the JSON diff preview. This preview is displayed in the upgrade prebuilt rule flyout. <img width="1209" alt="Schermafbeelding 2024-01-31 om 10 38 51" src="https://github.com/elastic/kibana/assets/15949146/9f4ffcca-31fe-464e-9315-c90ec38696d6">
**Resolves: elastic#166163 Flaky test runner runs: [1](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5189), [2](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5190), [3](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5191), [4](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/5192) ## Summary This PR adds tests in accordance with the [test plan](elastic#175958) that was merged earlier.
Resolves: #166162
This PR introduces a test plan for the JSON diff preview. This preview is displayed in the upgrade prebuilt rule flyout.