Skip to content
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][Detection Engine] ML Cypress Improvements #186831

Merged
merged 3 commits into from
Jun 25, 2024

Conversation

rylnd
Copy link
Contributor

@rylnd rylnd commented Jun 24, 2024

Summary

This PR contains a collection of fixes, mainly cherry-picked from #181926. Since some of these tests are failing sporadically on main, I'm opening this "test fix" PR for expedience while #181926 is still in review.

Checklist

@rylnd rylnd added the Team:Detection Engine Security Solution Detection Engine Area label Jun 24, 2024
@rylnd rylnd changed the title [Security Solution][Detection Engine] ML Cypress Improvements [Security Solution][Detection Engine] ML Integration Test Improvements Jun 24, 2024
@rylnd
Copy link
Contributor Author

rylnd commented Jun 24, 2024

/ci

This commit contains a few improvements, cherry-picked from elastic#181926.
Full context/details can be found there, but I'll try to summarize
below:

* ML form helpers receive normal rule parameters (instead of humanized
  job names)
* Better starting state: deletes rules and stops ML jobs before test
  suite
* Relaxed assertions: removes assertions that fail if there's more than
  one test in the environment (this is somewhat redundant with the
  previous improvement, but no harm in having both).
@rylnd rylnd force-pushed the ml_cypress_improvements branch from 906b70d to 8b3afa3 Compare June 24, 2024 18:49
@rylnd rylnd changed the title [Security Solution][Detection Engine] ML Integration Test Improvements [Security Solution][Detection Engine] ML Cypress Improvements Jun 24, 2024
@rylnd
Copy link
Contributor Author

rylnd commented Jun 24, 2024

/ci

@rylnd rylnd marked this pull request as ready for review June 24, 2024 20:24
@rylnd rylnd requested review from a team as code owners June 24, 2024 20:24
@rylnd rylnd requested a review from dhurley14 June 24, 2024 20:24
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-detection-engine (Team:Detection Engine)

@rylnd rylnd added the release_note:skip Skip the PR/issue when compiling release notes label Jun 24, 2024
@elastic elastic deleted a comment from kibanamachine Jun 24, 2024
@elastic elastic deleted a comment from kibanamachine Jun 24, 2024
@kibanamachine
Copy link
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#6381

[✅] Security Solution Detection Engine - Cypress: 100/100 tests passed.

see run history

@kibanamachine
Copy link
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#6382

[✅] [Serverless] Security Solution Detection Engine - Cypress: 100/100 tests passed.

see run history

@kibanamachine
Copy link
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#6385

[✅] Security Solution Detection Engine - Cypress: 100/100 tests passed.

see run history

@kibanamachine
Copy link
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#6386

[✅] [Serverless] Security Solution Detection Engine - Cypress: 100/100 tests passed.

see run history

Copy link
Contributor

@dhurley14 dhurley14 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are three functions added here that aren't used in the changes. Not sure if we plan on using these in the future but maybe we should remove them from this PR until they are utilized.

These were cherry-picked from the ML suppression branch, where they're
used more fully. For now, we only use forceStopAndCloseJob to get a
clean test state.
@rylnd rylnd requested a review from MadameSheema June 25, 2024 16:27
@rylnd
Copy link
Contributor Author

rylnd commented Jun 25, 2024

@dhurley14 I removed those unused helpers from this PR 👍

@rylnd rylnd requested a review from dhurley14 June 25, 2024 16:29
Copy link
Contributor

@dhurley14 dhurley14 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@rylnd rylnd enabled auto-merge (squash) June 25, 2024 19:41
@kibana-ci
Copy link
Collaborator

💛 Build succeeded, but was flaky

Failed CI Steps

Metrics [docs]

✅ unchanged

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@rylnd rylnd merged commit 0d802cb into elastic:main Jun 25, 2024
40 checks passed
@kibanamachine kibanamachine added v8.15.0 backport:skip This commit does not require backporting labels Jun 25, 2024
@rylnd rylnd deleted the ml_cypress_improvements branch June 25, 2024 21:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:Detection Engine Security Solution Detection Engine Area v8.15.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants