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

[ML] Functional tests - fix and re-enable close_jobs API tests #103114

Merged
merged 1 commit into from
Jun 24, 2021

Conversation

pheyos
Copy link
Member

@pheyos pheyos commented Jun 23, 2021

Summary

This PR fixes and re-enables the close_jobs API tests after a backend change.

Details

  • The close job behavior has been changed on the backend in [ML] Closing an anomaly detection job now automatically stops its datafeed if necessary elasticsearch#74257 (tl;dr: closing a job with a started datafeed doesn't fail anymore but instead automatically stops the datafeed).
  • High level tests before this PR:
    • set up jobs once for all following tests
    • try to close without proper privileges -> expect to fail
    • try to close with datafeed still running -> expect to fail
    • stop datafeeds
    • try to close again -> expect success
  • High level tests after this PR:
    • set up and clean jobs separately for each of the following tests
    • try to close without proper privileges -> expect to fail
    • try to close with datafeed still running -> expect success + datafeed auto-stopped
    • try to close with datafeed not running -> expect success
    • try to close when already closed -> expect success

Closes #103023

@pheyos pheyos added :ml v8.0.0 release_note:skip Skip the PR/issue when compiling release notes test-api-integration v7.14.0 labels Jun 23, 2021
@pheyos pheyos requested a review from a team as a code owner June 23, 2021 15:00
@pheyos pheyos self-assigned this Jun 23, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/ml-ui (:ml)

@qn895
Copy link
Member

qn895 commented Jun 23, 2021

LGTM 🎉

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

✅ unchanged

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

cc @pheyos

Copy link
Contributor

@peteharverson peteharverson left a comment

Choose a reason for hiding this comment

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

LGTM

@pheyos pheyos added the auto-backport Deprecated - use backport:version if exact versions are needed label Jun 24, 2021
@pheyos pheyos merged commit 6a1e4b8 into elastic:master Jun 24, 2021
@pheyos pheyos deleted the fix_close_job_tests branch June 24, 2021 08:58
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jun 24, 2021
…ic#103114)

This PR fixes and re-enables the close_jobs API tests after a backend change.
@kibanamachine
Copy link
Contributor

💚 Backport successful

Status Branch Result
7.x

This backport PR will be merged automatically after passing CI.

kibanamachine added a commit that referenced this pull request Jun 24, 2021
…) (#103218)

This PR fixes and re-enables the close_jobs API tests after a backend change.

Co-authored-by: Robert Oskamp <robert.oskamp@elastic.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Deprecated - use backport:version if exact versions are needed :ml release_note:skip Skip the PR/issue when compiling release notes test-api-integration v7.14.0 v8.0.0
Projects
None yet
5 participants