-
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][Detections] Fix flaky threshold API tests #97768
[Security Solution][Detections] Fix flaky threshold API tests #97768
Conversation
Pinging @elastic/security-detections-response (Team:Detections and Resp) |
Pinging @elastic/security-solution (Team: SecuritySolution) |
@elasticmachine merge upstream |
1 similar comment
@elasticmachine merge upstream |
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!
cb1da46
to
b03a8be
Compare
💛 Build succeeded, but was flaky
Test FailuresKibana Pipeline / general / X-Pack API Integration Tests.x-pack/test/api_integration/apis/lens/field_stats·ts.apis Lens index stats apis field distribution "before all" hook for "should return a 404 for missing index patterns"Standard Out
Stack Trace
Kibana Pipeline / general / X-Pack API Integration Tests.x-pack/test/api_integration/apis/lens/field_stats·ts.apis Lens index stats apis field distribution "after all" hook for "should apply filters and queries"Standard Out
Stack Trace
Kibana Pipeline / general / X-Pack API Integration Tests.x-pack/test/api_integration/apis/lens/field_stats·ts.apis Lens index stats apis "after all" hook in "index stats apis"Standard Out
Stack Trace
Metrics [docs]
History
To update your PR or re-run it, just comment with: |
…c#97768) * Explicitly refreshes signals index for threshold api tests to prevent flakiness * Unskip test suite
…c#97768) * Explicitly refreshes signals index for threshold api tests to prevent flakiness * Unskip test suite
#97897) * Explicitly refreshes signals index for threshold api tests to prevent flakiness * Unskip test suite Co-authored-by: Marshall Main <55718608+marshallmain@users.noreply.github.com>
#97898) * Explicitly refreshes signals index for threshold api tests to prevent flakiness * Unskip test suite Co-authored-by: Marshall Main <55718608+marshallmain@users.noreply.github.com>
Summary
Threshold API integration tests added in #97336 were waiting for the rule status to update, but were not refreshing the index or retrying multiple times to wait for the index to refresh, causing flaky tests. This PR explicitly refreshes the index before retrieving signals so any newly created signals will be properly returned.
Checklist
Delete any items that are not applicable to this PR.
For maintainers