-
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][Endpoint] Endpoint generator and data loader support for Host Isolation #100813
[Security Solution][Endpoint] Endpoint generator and data loader support for Host Isolation #100813
Conversation
…endpoint generator and test data loader (elastic#100727) * Generate random isolation values for endpoint metadata * Generator for Fleet Actions * Added creation of actions to the index test data loader (cherry picked from commit 57f59bd)
Pinging @elastic/security-onboarding-and-lifecycle-mgt (Team:Onboarding and Lifecycle Mgt) |
|
||
/** Generate either `true` or `false` */ | ||
protected randomBoolean(): boolean { | ||
return this.random() < 0.5; |
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.
the bug fix for the problem that was introduced originally is here. Instead of using Math.random()
, we need to use this.random()
which is a seeded random number generator
@oatkiller , @jonathan-buttner , In talking with @pzl , having the data generator tied/coupled to tests seems troublesome. We might break out the generation of the Endpoint Host metadata into a separate generator (similar to the new one under |
Yeah that might have been a poor choice on my part 😬 . Maybe we should hard code the values in the tests. It was just really convenient to have the generator create the data that we needed at the time. |
@jonathan-buttner thanks for the review. No worries. Yeah, we have used the endpoint generator in our tests, but usually will statically set the properties we're looking to test. we also try not to use snapshots too much because of issues like this 😄 Thanks again |
💛 Build succeeded, but was flaky
Test FailuresKibana Pipeline / general / "before all" hook for "should not allow user with read only privileges to attach alerts to cases".Alerts timeline Privileges: read only "before all" hook for "should not allow user with read only privileges to attach alerts to cases"Stack Trace
Metrics [docs]History
To update your PR or re-run it, just comment with: |
…ort for Host Isolation (elastic#100813) Re-introduces the changes from elastic#100727 which was backed out due to a bug. Changes included: * Generate random isolation values for endpoint metadata * Generator for Fleet Actions * Added creation of actions to the index test data loader Plus: * Fix generator `randomBoolean()` to ensure it works with seeded random numbers * Update resolver snapshots due to additional call to randomizer
💚 Backport successful
This backport PR will be merged automatically after passing CI. |
…ort for Host Isolation (#100813) (#100904) Re-introduces the changes from #100727 which was backed out due to a bug. Changes included: * Generate random isolation values for endpoint metadata * Generator for Fleet Actions * Added creation of actions to the index test data loader Plus: * Fix generator `randomBoolean()` to ensure it works with seeded random numbers * Update resolver snapshots due to additional call to randomizer Co-authored-by: Paul Tavares <[email protected]>
* master: (77 commits) [RAC][Security Solution] Register Security Detection Rules with Rule Registry (elastic#96015) [Enterprise Search] Log warning for Kibana/EntSearch version mismatches (elastic#100809) updating the saved objects test to include more saved object types (elastic#100828) [ML] Fix categorization job view examples link when datafeed uses multiple indices (elastic#100789) Fixing ES archive mapping failure (elastic#100835) Fix bug with Observability > APM header navigation (elastic#100845) [Security Solution][Endpoint] Add event filters summary card to the fleet endpoint tab (elastic#100668) [Actions] Taking space id into account when creating email footer link (elastic#100734) Ensure comments on parameters in arrow functions are captured in the docs and ci metrics. (elastic#100823) [Security Solution] Improve find rule and find rule status route performance (elastic#99678) [DOCS] Adds video to introduction (elastic#100906) [Fleet] Improve combo box for fleet settings (elastic#100603) [Security Solution][Endpoint] Endpoint generator and data loader support for Host Isolation (elastic#100813) [DOCS] Adds Lens video (elastic#100898) [TSVB] [Table tab] Fix "Math" aggregation (elastic#100765) chore(NA): moving @kbn/io-ts-utils into bazel (elastic#100810) [Alerting] Adding feature flag for enabling/disabling rule import and export (elastic#100718) [TSVB] Fix Upgrading from 7.12.1 to 7.13.0 breaks TSVB (elastic#100864) [Lens] Adds dynamic table cell coloring (elastic#95217) [Security Solution][Endpoint] Do not display searchbar in security-trusted apps if there are no items (elastic#100853) ...
Summary
Re-introduces commit 57f59bd which was backed out due to a bug
Original Commit: #100727
Closes #100800